ObservedInteger
ObservedInteger
Kind: global class
- ObservedInteger
- new ObservedInteger([value])
- .onChanged :
Signal
- .isObservedInteger :
boolean
- .valueOf() ⇒
Number
- .set(value) ⇒
ObservedInteger
- .setSilent(value)
- .isZero() ⇒
boolean
- .subtract(other)
- ._subtract(value)
- .add(other)
- ._add(value)
- .increment()
- .decrement()
- .getValue() ⇒
Number
- .copy(other)
- .equals(other) ⇒
boolean
- .hash() ⇒
Number
- .toBinaryBuffer(buffer)
- .fromBinaryBuffer(buffer)
new ObservedInteger([value])
Param | Type | Default |
---|---|---|
[value] | Number | 0 |
observedInteger.onChanged : Signal
Kind: instance property of ObservedInteger
Read only: true
observedInteger.isObservedInteger : boolean
Kind: instance property of ObservedInteger
Read only: true
observedInteger.valueOf() ⇒ Number
Kind: instance method of ObservedInteger
observedInteger.set(value) ⇒ ObservedInteger
Kind: instance method of ObservedInteger
Param | Type |
---|---|
value | Number |
observedInteger.setSilent(value)
Set value without dispatching change notification
Kind: instance method of ObservedInteger
Param | Type |
---|---|
value | number |
observedInteger.isZero() ⇒ boolean
Kind: instance method of ObservedInteger
observedInteger.subtract(other)
Kind: instance method of ObservedInteger
Param | Type |
---|---|
other | ObservedInteger |
observedInteger._subtract(value)
Kind: instance method of ObservedInteger
Param | Type |
---|---|
value | number |
observedInteger.add(other)
Kind: instance method of ObservedInteger
Param | Type |
---|---|
other | ObservedInteger |
observedInteger._add(value)
Kind: instance method of ObservedInteger
Param | Type |
---|---|
value | number |
observedInteger.increment()
Increment the stored value by 1, same as adding 1
Kind: instance method of ObservedInteger
observedInteger.decrement()
Decrement the stored value by 1, same as subtracting 1
Kind: instance method of ObservedInteger
observedInteger.getValue() ⇒ Number
Kind: instance method of ObservedInteger
observedInteger.copy(other)
Kind: instance method of ObservedInteger
Param | Type |
---|---|
other | ObservedInteger |
observedInteger.equals(other) ⇒ boolean
Kind: instance method of ObservedInteger
Param | Type |
---|---|
other | ObservedInteger |
observedInteger.hash() ⇒ Number
Kind: instance method of ObservedInteger
observedInteger.toBinaryBuffer(buffer)
Kind: instance method of ObservedInteger
Param | Type |
---|---|
buffer | BinaryBuffer |
observedInteger.fromBinaryBuffer(buffer)
Kind: instance method of ObservedInteger
Param | Type |
---|---|
buffer | BinaryBuffer |