Class: Entry
Defined in: src/model/entry.js:7
An entry represents either an argument or a property to a node
Constructors
new Entry()
new Entry(
value,name):Entry
Defined in: src/model/entry.js:80
Parameters
| Parameter | Type | Description |
|---|---|---|
value | Value | |
name | null | Identifier |
Returns
Properties
equals
equals:
undefined|string
Defined in: src/model/entry.js:74
Equals sign
leading
leading:
undefined|string
Defined in: src/model/entry.js:60
Leading whitespace
name
name:
null|Identifier
Defined in: src/model/entry.js:46
The name of this entry if it's a property, or null if it's an argument
trailing
trailing:
undefined|string
Defined in: src/model/entry.js:67
Trailing whitespace
value
value:
Value
Defined in: src/model/entry.js:53
The value of this entry
Methods
clone()
clone():
Entry
Defined in: src/model/entry.js:90
Create an identical copy of this entry
Returns
getName()
getName():
null|string
Defined in: src/model/entry.js:125
Return the name of this entry, if any
Returns
null | string
getTag()
getTag():
null|string
Defined in: src/model/entry.js:106
Return the tag of this entry, if any
Returns
null | string
See
getValue()
getValue():
Primitive
Defined in: src/model/entry.js:143
Return the value of this entry
Returns
isArgument()
isArgument():
boolean
Defined in: src/model/entry.js:161
Return whether this entry is an argument
Returns
boolean
isProperty()
isProperty():
boolean
Defined in: src/model/entry.js:170
Return whether this entry is a named property
Returns
boolean
setName()
setName(
name):void
Defined in: src/model/entry.js:134
Set the name of this entry to the given name
Parameters
| Parameter | Type | Description |
|---|---|---|
name | undefined | null | string |
Returns
void
setTag()
setTag(
tag):void
Defined in: src/model/entry.js:116
Set the tag of this entry to the given tag
Parameters
| Parameter | Type | Description |
|---|---|---|
tag | undefined | null | string |
Returns
void
See
setValue()
setValue(
value):void
Defined in: src/model/entry.js:152
Set the name of this entry to the given name
Parameters
| Parameter | Type | Description |
|---|---|---|
value | Primitive |
Returns
void
createArgument()
staticcreateArgument(value):Entry
Defined in: src/model/entry.js:14
Create a new argument entry with the given value
Parameters
| Parameter | Type | Description |
|---|---|---|
value | Primitive |
Returns
createProperty()
staticcreateProperty(name,value):Entry
Defined in: src/model/entry.js:25
Create a new property entry for the given key and value
Parameters
| Parameter | Type | Description |
|---|---|---|
name | string | |
value | Primitive |