This is a convenience object that wraps a javascript `null`. These are returned when a RealTimeObject or RealTimeArray contains a null value. The `value()` of this is always `null` and cannot be changed.

See RealTimeNullEvents for the events that can be emitted on remote changes to this object.

More information is in the developer guide.

### Hierarchy

- RealTimeElement<void>
  - RealTimeNull

### Implements

- ObservableElement<void>
- ObservableNull

## Index

### Properties

- Events

### Methods

- addListener
- events
- id
- isAttached
- isDetached
- model
- off
- on
- once
- parent
- path
- reference
- references
- relativePath
- removeAllListeners
- removeFromParent
- removeListener
- removeListeners
- toJSON
- type
- value

## Properties

### StaticEvents

Events: RealTimeNullEvents = ObservableNullEventConstants

Overrides RealTimeElement.Events

## Methods

### addListener

- addListener(event: string, listener: ConvergenceEventListener<IConvergenceEvent>): ConvergenceEventEmitter<IConvergenceEvent>

- Implementation of ObservableNull.addListener

  Inherited from ConvergenceEventEmitter.addListener

  Adds a new event listener for the specified event. The class will ignore duplicate registrations of the same listener to the same event.

  #### Parameters

  - ##### event: string

    The name of the event to add the listener for.

  - ##### listener: ConvergenceEventListener<IConvergenceEvent>

    The listener callback to register.

  #### Returns ConvergenceEventEmitter<IConvergenceEvent>

  This object, in support of a fluent API.

### events

- events(): Observable<IConvergenceEvent>

- Implementation of ObservableNull.events

  Inherited from ConvergenceEventEmitter.events

  Provides the events emitted by this object as an Observable stream.

  example

        eventEmitter.events()
          .filter(e => e.name === "myevent")
          .subscribe(e => console.log(e));

  #### Returns Observable<IConvergenceEvent>

  An Observable stream of all events emitted by this object.

### id

- id(): string

- Implementation of ObservableNull.id

  Inherited from RealTimeBoolean.id

  Each node within a RealTimeModel has a system-generated ID that is unique within this model's contents.

  #### Returns string

  a unique (to the model) ID for this element

### isAttached

- isAttached(): boolean

- Implementation of ObservableNull.isAttached

  Inherited from RealTimeBoolean.isAttached

  True if the element is currently set up to synchronize with the server.

  #### Returns boolean

### isDetached

- isDetached(): boolean

- Implementation of ObservableNull.isDetached

  Inherited from RealTimeBoolean.isDetached

  True if the element is no longer synchronizing with the server. See the developer guide for more information.

  #### Returns boolean

### model

- model(): RealTimeModel

- Implementation of ObservableNull.model

  Inherited from RealTimeBoolean.model

  Returns the model to which this element belongs.

  #### Returns RealTimeModel

### off

- off(event: string, listener: ConvergenceEventListener<IConvergenceEvent>): ConvergenceEventEmitter<IConvergenceEvent>

- Implementation of ObservableNull.off

  Inherited from ConvergenceEventEmitter.off

  Removes a single event listener for a specific event.

  #### Parameters

  - ##### event: string

    The name of the event to remove the listener for.

  - ##### listener: ConvergenceEventListener<IConvergenceEvent>

    The listener callback to unregister.

  #### Returns ConvergenceEventEmitter<IConvergenceEvent>

  This object, in support of a fluent API.

### on

- on(event: string, listener: ConvergenceEventListener<IConvergenceEvent>): ConvergenceEventEmitter<IConvergenceEvent>

- Implementation of ObservableNull.on

  Inherited from ConvergenceEventEmitter.on

  Adds a new event listener for the specified event. The class will ignore duplicate registrations of the same listener to the same event.

  #### Parameters

  - ##### event: string

    The name of the event to add the listener for.

  - ##### listener: ConvergenceEventListener<IConvergenceEvent>

    The listener callback to register.

  #### Returns ConvergenceEventEmitter<IConvergenceEvent>

  This object, in support of a fluent API.

### once

- once(event: string, listener: ConvergenceEventListener<IConvergenceEvent>): ConvergenceEventEmitter<IConvergenceEvent>

- Implementation of ObservableNull.once

  Inherited from ConvergenceEventEmitter.once

  Adds a single shot event listener for the specified event. The listener will be called the first time the specified event is fired after the event registration occurs, after which the registration will be removed and no further events will be passed to the listener.

  #### Parameters

  - ##### event: string

    The name of the event to add the listener for.

  - ##### listener: ConvergenceEventListener<IConvergenceEvent>

    The listener callback to register.

  #### Returns ConvergenceEventEmitter<IConvergenceEvent>

  This object, in support of a fluent API.

### parent

- parent(): RealTimeContainerElement<any>

- Implementation of ObservableNull.parent

  Inherited from RealTimeBoolean.parent

  Returns the parent of this element within the model.

  #### Returns RealTimeContainerElement<any>

  the parent of this element, or `this` if this is the root element

### path

- path(): Path

- Implementation of ObservableNull.path

  Inherited from RealTimeBoolean.path

  The Path representing this element's location in the containing model's data. For instance, with model data

      {
        user: {
          age: 32
        }
      }

  The RealTimeNumber representing `32` would have path `['user', 'age']`.

  #### Returns Path

### reference

- reference(sessionId: string, key: string): ModelReference<any>

- Inherited from RealTimeBoolean.reference

  Returns the remote ModelReference created by the given `sessionId` with the unique name `key`, or `undefined` if no such reference exists.

  See Remote References in the developer guide.

  #### Parameters

  - ##### sessionId: string

    The session ID that created the reference

  - ##### key: string

    the reference's unique key

  #### Returns ModelReference<any>

### references

- references(referenceFilter?: ReferenceFilter): Array<ModelReference<any>>

- Inherited from RealTimeBoolean.references

  Returns any remote references that match the given filter. You can provide a single `key` which could return references from multiple users, `sessionId` which would return all of a particular user session's references, or both, which is really just the same as using the reference method.

  #### Parameters

  - ##### Optional referenceFilter: ReferenceFilter

  #### Returns Array<ModelReference<any>>

  An array of remote ModelReferences, or an empty array if there were no matches.

### relativePath

- relativePath(): PathElement

- Implementation of ObservableNull.relativePath

  Inherited from RealTimeBoolean.relativePath

  This returns the PathElement representing this element's location relevant to its parent. For example, given a model with contents

      {
        obj: {
          with: 1,
          stuff: ['a', 'string']
        }
      }

      let rtNumber = rtModel.elementAt(['obj', 'with']);
      rtNumber.value() // 1
      rtNumber.relativePath() // 'with'

      let rtString = rtModel.elementAt(['obj', 'stuff', 0]);
      rtString.value() // 'a'
      rtString.relativePath() // 0

  #### Returns PathElement

  a PathElement representing this node's location relative to its parent, or null if it has no parent.

### removeAllListeners

- removeAllListeners(): ConvergenceEventEmitter<IConvergenceEvent>

- Implementation of ObservableNull.removeAllListeners

  Inherited from ConvergenceEventEmitter.removeAllListeners

  Removes all listeners for all events. This is useful for cleanup before disposing of this particular event emitter.

  #### Returns ConvergenceEventEmitter<IConvergenceEvent>

  This object, in support of a fluent API.

### removeFromParent

- removeFromParent(): void

- Inherited from RealTimeBoolean.removeFromParent

  A convenience function to delete this element. Throws an error if this is the root object in a model.

  #### Returns void

### removeListener

- removeListener(event: string, listener: ConvergenceEventListener<IConvergenceEvent>): ConvergenceEventEmitter<IConvergenceEvent>

- Implementation of ObservableNull.removeListener

  Inherited from ConvergenceEventEmitter.removeListener

  Removes a single event listener for a specific event.

  #### Parameters

  - ##### event: string

    The name of the event to remove the listener for.

  - ##### listener: ConvergenceEventListener<IConvergenceEvent>

    The listener callback to unregister.

  #### Returns ConvergenceEventEmitter<IConvergenceEvent>

  This object, in support of a fluent API.

### removeListeners

- removeListeners(event: string): ConvergenceEventEmitter<IConvergenceEvent>

- Implementation of ObservableNull.removeListeners

  Inherited from ConvergenceEventEmitter.removeListeners

  Removes all listeners bound on the given event.

  #### Parameters

  - ##### event: string

    the name of the event to remove listeners for

  #### Returns ConvergenceEventEmitter<IConvergenceEvent>

  This object, in support of a fluent API.

### toJSON

- toJSON(): any

- Implementation of ObservableNull.toJSON

  Inherited from RealTimeBoolean.toJSON

  Returns a JSON-compatible representation of this element.

  #### Returns any

### type

- type(): string

- Implementation of ObservableNull.type

  Inherited from RealTimeBoolean.type

  This element's type. See [[ModelElementType]] for an enumeration of types.

  #### Returns string

### value

- value(): void
- value(value: void): void

- Implementation of ObservableNull.value

  Inherited from RealTimeBoolean.value

  Returns the current underlying value of this element. Note that the return value will not be kept up to date automatically; rather, this function will need to be called each time the most up-to-date value is required.

  #### Returns void

- Inherited from RealTimeBoolean.value

  Sets the value of this element, whose type must be the underlying type of this object.

  On a succesful `value` call, the appropriate IValueChangedEvent will be emitted to any remote users. This will be one of:

  - ArraySetValueEvent
  - BooleanSetValueEvent
  - DateSetValueEvent
  - NumberSetValueEvent
  - ObjectSetValueEvent
  - StringSetValueEvent

  #### Parameters

  - ##### value: void

    the new value for this object.

  #### Returns void