Model class

A PureMVC MultiCore IModel implementation.

In PureMVC, IModel implementors provide access to IProxy objects by named lookup.

An IModel assumes these responsibilities:

  • Maintain a cache of IProxy instances.
  • Provide methods for registering, retrieving, and removing IProxy instances.

Your application must register IProxy instances with the IModel. Typically, you use an ICommand to create and register IProxy instances once the IFacade has initialized the core actors.

See IProxy, IFacade

Implemented types

Constructors

Model(String key)
Constructor. [...]

Properties

hashCode int
The hash code for this object. [...]
read-only, inherited
multitonKey String
read / write, override
proxyMap Map<String, IProxy>
read / write
runtimeType Type
A representation of the runtime type of the object.
read-only, inherited

Methods

hasProxy(String proxyName) bool
Check if an IProxy is registered with the IModel. [...]
override
initializeModel() → void
Initialize the IModel instance. [...]
noSuchMethod(Invocation invocation) → dynamic
Invoked when a non-existent method or property is accessed. [...]
inherited
registerProxy(IProxy proxy) → void
Register an IProxy instance with the IModel. [...]
override
removeProxy(String proxyName) IProxy
Remove an IProxy instance from the IModel. [...]
override
retrieveProxy(String proxyName) IProxy
Retrieve an IProxy instance from the IModel. [...]
override
toString() String
A string representation of this object. [...]
inherited

Operators

operator ==(Object other) bool
The equality operator. [...]
inherited

Static Properties

instanceMap Map<String, IModel>
read / write

Static Methods

getInstance(String key) IModel
IModel Multiton Factory method. [...]
removeModel(String key) → void
Remove an IModel instance. [...]