Special Gosu expressions

The Gosu syntax supports the following types of specialized Gosu expressions:
  • Functions
  • Static methods
  • Static property paths
  • Entity literals
  • Typekey literals

Function calls

This expression calls a function with an optional list of arguments and returns the result.

Syntax

functionName(argumentList)

Examples

Expression

Result

now()

Current Date

concat("limited-", "coverage")

"limited-coverage"

Static method calls

This expression calls a a static method on a type with an optional list of arguments and returns the result.

Syntax

typeExpression.staticMethodName(argumentList)

Examples

Expression

Result

java.lang.System.currentTimeMillis()

Current time

java.util.Calendar.getInstance()

Java Calendar

See also

Static property paths

Gosu uses the dot-separated path rooted at a Type expression to retrieve the value of a static property.

Syntax

TypeExpression.StaticProperty

Examples

Expression

Result

Claim.TypeInfo

Claim typeInfo

LossCause.TC_HAIL

"hail" typekey

java.util.Calendar.FRIDAY

Friday value

See also

Entity and typekey type literals

Gosu supports referencing an entity or typekey type by relative name, or by fully qualified name:

  • A fully qualified entity name begins with “entity.”.
  • A fully qualified typekey begins with “typekey.”.

Syntax

[entity.]typeName
[typekey.]typeName

Examples

Expression

Result

Claim

Claim type

entity.Claim

Claim type

LossCause

LossCause type

typekey.LossCause

LossCause type

java.lang.String

String type

int

int type