From wiki.ginstr.com
Jump to: navigation, search

This page describes how GBAM generates certain id's for xml of ginstr app.

User inputs

User entered data in GBAM UI that is used in ID's generation:

${appName}

  • ${appName} is user entered content in GBAM input field "app name" in "general app settings" panel. Represents the name of ginstr app.
  • user entered content is modified and generates = ${appNameGenerated} according to rules below

${screenLabel}

  • ${screenLabel} is user entered content in GBAM input field "screen name" in section "general settings" of "properties" panel. Represents the name of the screen.
  • user entered content is modified and generates = ${screenLabelGenerated} according to rules below

${widgetLabel}

from columns: gBAM UI name (xx) where XX: localization of the ginstr app that is set in gBAM.

APP ID ${appNameGenerated}

  • ginstr app id generated that only latin alpha numeric characters are allowed and "_". [^A-Z0-9_]+
  • input is modified to camel case syntax
  • if user enters all illegal characters then app name is generated like : myGinstrApp_ddmmYYYYY (where dd is day, mm month, YYYY year)

Examples: ${appName} = ${appNameGenerated}

  • my cool ginstr app = myCoolGinstrApp
  • 12my app IS NICE = 12myAppIsNice
  • #$%some_Appname here = someAppnameHere
  • #$&/(/() = myGinstrApp_08112016

WIDGET LABEL ${widgetLabelGenerated}

  • widget label is generated that only latin alpha numeric characters are allowed [^A-Z0-9]+
  • input is modified to camel case syntax
  • if user enters all illegal characters then app name is generated using : ${widgetID}Iterator (Iterator - if there is more then one widget then this is set to number which is next in widgets on screen count) .
  • Widget ID is defined on every widget wiki page at the top.

Examples: ${widgetLabel} = ${widgetLabelGenerated}

  • first name = firstName
  • my#last name = myLastName
  • $$/"$/ = textEditable2, (in this example if ${widgetID} is textEditable and it's a second widget of that type on screen)
  • My_underscored widget l#abel = myUnderscoredWidgetLabel

WIDGET ID'S ${widgetID}

Widget ID is formed in combination with ${screenLabelGenerated} and ${widgetLabelGenerated}

Definition for ${widgetID}:

  • ${screenLabelGenerated}_${widgetLabelGenerated}_widgetSuffix

"widgetSuffix" - depends on which widget is used , can be i.e. "_input" for Text#textEditable

Definition for ${widgetID} when used for string resourceID @string/:

  • ${screenLabelGenerated}_${widgetLabelGenerated}

Examples:
User entered:

  • ${screenLabel} = first page
  • ${widgetLabel} = my cool widget

Result:

  • firstPage_myCoolWidget_widgetSuffix

Result for @string/:

  • firstPage_myCoolWidget

User entered:

Result:

  • screenScroll_textEditable_input

Result for @string/:

  • screenScroll_textEditable

SCREEN ID'S ${screenLabelGenerated}

DATABASE TABLE ID ${tableName}

  • database table name is currently hardcoded: reports


DATABASE COLUMN ID'S ${columnName}

  • column names are currently generated: report_${screenLabelGenerated}_${widgetLabelGenerated}

Examples:

  • report_screen1_myWidget
  • report_screen_mySecondWidget

STRING RESOURCE ID'S @string/

  • string resource id's are formed by naming convention
  • naming convention: convention