new Resource([options])

Parameter

Name Type Optional Description

options

 

Yes

Options.

Properties

_offset  (undefined or integer)

_run  (undefined or Date)

datetime  (Date or undefined)

Resource is valid for this datetime. If undefined, than the resource is not only valid at one datetime.

offset  (integer or undefined)

Offset.

run  (Date or undefined)

Runtime.

read-only

variables  Array of module:meteoJS/modelviewer/variable.Variable

Variable objects, which define this resource. Like model, run, offset,…

Methods

getVariableByVariableCollection(variableCollection) → module:meteoJS/modelviewer/variable.Variable

Returns the variable-object that is part of the definition of this resource and contains to the passed collection. If you define the resource by several variables of the same variable collection, it is not defined which variable is returned.

Parameter

Name Type Optional Description

variableCollection

module:meteoJS/modelviewer/variableCollection.VariableCollection

 

VariableCollection.

Returns

module:meteoJS/modelviewer/variable.Variable 

isDefinedBy([exactlyMatch], ...variables) → boolean

Returns if the passed Variable-objects all define this resource.

Parameters

Name Type Optional Description

exactlyMatch

boolean

Yes

Only return true, if the passed variables exactly define the resource.

variables

module:meteoJS/modelviewer/variable.Variable

 

Variables.

Value can be repeated.

Returns

boolean All passed variables defines the resource.

isDefinedByVariableOf(variableCollection) → boolean

Returns if a Variable-object of the passed collection defines this resource.

Parameter

Name Type Optional Description

variableCollection

module:meteoJS/modelviewer/variableCollection.VariableCollection

 

VariableCollection.

Returns

boolean A variable of the collection defines the resource.