Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

...

Here are some commonly used conventions for the identifier suffixes:

SuffixExampleLabelMeaning
DiffVolumeDiffVolume ∆Represents the difference between an actual and previous value
AbsMarginAbsMargin $Margin represented as an amount (typically formatted as Money)
PctMarginPctMargin %Margin represented as a percentage (typically formatted as Percent)
spxRecords
Represents a list of values

The suffixes can be combined. 

...

The general rule is to make the first letter uppercase

Example: DefaultLogic, Pricelist, Main, DefaultQuoteLogic

...

In order to make the auto-completion work in Pricefx Studio or to be able to run the debugging functionality or execute TDD4C tests without marking the folders as a source in Studio, it is recommended to always use a different element name which is unique within the project. Also the element name "Filter" is not recommended, since the auto-completion collides with the standard Filter object used frequently by the logics.

The groovy Groovy library element names should have a suffix "Utils" (e.g. RoundingUtils, CacheUtils, DatamartUtils).

Example: NewMargin, SalesPrice

Element Labels

...

The general rule is to make the first letter lowercase. Even though Groovy, compared to Java, allows the first letter in uppercase, it is recommended to follow the Java convention.

Example: newMargin, salesPrice

If the variable stores a list of values, then the suffix "s" (English plural) can give a hint that it stores multiple values.

...

The general rule is to make the first letter lowercase. Even though Groovy, compared to Java, allows the first letter in uppercase, it is recommended to follow the Java convention.

Example: getCostPrice()

DF/DS/DM Fields

...

Note: In SQL queries the fields are referred to in lowercase.

Example: NewMargin, SalesPrice