Class: SetAttribute

metamodel.SetAttribute(name, elementType, flagsopt)

new SetAttribute(name, elementType, flagsopt)

Parameters:
Name Type Attributes Description
name string
elementType metamodel.Type
flags Object <optional>
Source:

Extends

Members

(static) ref

Get the type id for this set type

Source:

accessor :binding.Accessor

Type:
Inherited From:
Source:

(readonly) collectionType :PluralAttribute.CollectionType

Returns the collection attribute type

Type:
  • PluralAttribute.CollectionType
Overrides:
Source:

declaringType :metamodel.ManagedType

Type:
Inherited From:
Source:

elementType :metamodel.Type

Type:
Inherited From:
Source:

isAcl :boolean

Type:
  • boolean
Inherited From:
Source:

(readonly) isAssociation :boolean

Type:
  • boolean
Inherited From:
Source:

(readonly) isCollection :boolean

Type:
  • boolean
Inherited From:
Source:

isId :boolean

Type:
  • boolean
Inherited From:
Source:

isMetadata :boolean

Type:
  • boolean
Inherited From:
Source:

isVersion :boolean

Type:
  • boolean
Inherited From:
Source:

metadata :Object.<string, string>|null

Type:
  • Object.<string, string> | null
Inherited From:
Source:

name :string

Type:
  • string
Inherited From:
Source:

order :number

Type:
  • number
Inherited From:
Source:

(readonly) persistentAttributeType :Attribute.PersistentAttributeType

Returns the persistent attribute type

Type:
  • Attribute.PersistentAttributeType
Inherited From:
Source:

typeConstructor :Class.<*>

Type:
  • Class.<*>
Overrides:
Source:

Methods

getJsonValue(state, object, options) → {*}

Gets this attribute value form the object as json

Parameters:
Name Type Description
state util.Metadata

The root object state

object *

The object which contains the value of this attribute

options Object

additional options which are applied through the conversion

Overrides:
Source:
Returns:

The converted json value

Type
*

getMetadata(key) → {null|string}

Gets some metadata of this type

Parameters:
Name Type Description
key string
Inherited From:
Source:
Returns:
Type
null | string

getValue(entity) → {*}

Parameters:
Name Type Description
entity Object
Inherited From:
Source:
Returns:
Type
*

hasMetadata(key) → {boolean}

Retrieves whether this type has specific metadata

Parameters:
Name Type Description
key string
Inherited From:
Source:
Returns:
Type
boolean

init(declaringType, order) → {void}

Parameters:
Name Type Description
declaringType metamodel.ManagedType

The type that owns this attribute

order number

Position of the attribute

Inherited From:
Source:
Returns:
Type
void

setJsonValue(state, object, jsonValue, options) → {void}

Sets this attribute value from json to the object

Parameters:
Name Type Description
state util.Metadata

The root state

object *

The object which contains the attribute

jsonValue *

The json value to convert an set

options Object

additional options which are applied through the conversion

Overrides:
Source:
Returns:
Type
void

setValue(entity, value) → {void}

Parameters:
Name Type Description
entity Object
value *
Inherited From:
Source:
Returns:
Type
void

toJSON() → {json}

Converts this attribute field to json

Overrides:
Source:
Returns:

The attribute description as json

Type
json