Child pages
  • JSDoc Annotations

Versions Compared

Key

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

...

Expression name

Syntax example

Context

Comments

Named type

{String}
{Boolean}
{Number}
{XML}
{XMLList}
{RuntimeForm}
{RuntimeLabel}
{JSButton}
{JSForm}

@param, @return, @type, @throws

The complete list of available types can be seen by triggering Code Completion inside the curly braces in the Script Editor

Any type

{*}
Any type of value

@param, @return, @type, @throws

This can be used to suppress some builder markers related to apparent type inconsistencies.

OR type

{String|Number}
Either a String or a Number

@param, @return, @type, @throws

 

REST type

{...String}
Indicates one or more String values

@param

Can only be used for the last declared parameter of a function

Array type

{String[]}
{Array<String>} 
An array containing just string values 

{Array<String|Number>}  
 An array containing string and/or number values 

{Array<Byte>}
An array containing just bytes

@param, @return, @type, @throws

 

Object type

{Object<String>}
An object where the value for each key is a String value

{Object<Array<String>>} 
An object where the value for each key contains arrays that in turn contains only string values

{ {name:String, age:Number}} 
An object with a "name" and "age" key, with resp. a string and number value

@param, @return, @type, @throws

 

Object type with optional properties

{ {name:String, [age]:Number}}
{ {name:String, age:Number=}}
An object with a "name" and optional "age" key, with resp. a string and number value

@param, @return, @type, @throws

 

Function type

{function(String, Number, Array<Object>):Boolean}
Between the bracket of the function the types of the function parameters can be sprecified. The functions returnType can be specified after the closing bracket, prefixed by a colon

@param, @return, @type

 

JSFoundset type

{JSFoundset<db:/udm/contacts>}1  
A JSFoundSet from the contacts table of the udm database server

{JSFoundset<{col1:String, col2:Number}>}
A JSFoundSet with dataproviders "col1" and "col2" with resp. string and number types

@param, @return, @type

 

JSRecord type

{JSRecord<db:/udm/contacts>}1
A JSRecord from the contacts table of the udm database server

{JSRecord<{col1:String, col2:Number}>}
A JSFoundSet with dataproviders "col1" and "col2" with resp. string and number types

@param, @return, @type

 

JSDataSet type

{JSDataSet<{name:String, age:Number}>}
An JSDataSet with a "name" and "age" column, with resp. a string and number value

@param, @return, @type

 

RuntimeForm type

{RuntimeForm<superFormName>}
A RuntimeForm that extends superFormName

@param, @return, @type

 

RuntimeWebComponent type{RuntimeWebComponent<webComponentName>}@param, @return, @type

The webComponentName can be found in the associated spec file; webComponentName may be for example: bootstrapcomponents-tabpanel (leading to the following type: {RuntimeWebComponent<bootstrapcomponents-tabpanel>} )

1 the value in between <..> is the datasource notation that is built up of the database server and tablename: db:/{serverName}/{tableName}

...