Packageorg.spicefactory.parsley.core.scope.impl
Classpublic class DefaultScope
InheritanceDefaultScope Inheritance Object
Implements Scope

Default implementation of the Scope interface.



Public Properties
 PropertyDefined By
  bindingManager : BindingManager
[read-only] The manager for publishers and subscribers of the decoupled binding facility.
DefaultScope
  commandManager : CommandManager
[read-only] The manager for active asynchronous commands in this scope.
DefaultScope
  extensions : ScopeExtensions
[read-only] Custom extensions registered for this scope.
DefaultScope
  inherited : Boolean
[read-only] Indicates whether this scope will be inherited by child Contexts.
DefaultScope
  lifecycleObservers : LifecycleObserverRegistry
[read-only] The registry for observers of lifecycle events dispatched by objects within this scope.
DefaultScope
  messageReceivers : MessageReceiverRegistry
[read-only] The registry for receivers of application messages dispatched through this scope.
DefaultScope
  name : String
[read-only] The name of the scope.
DefaultScope
  persistenceManager : PersistenceManager
[read-only] The manager for values persisted by publishers.
DefaultScope
  rootContext : Context
[read-only] The root Context of this scope.
DefaultScope
  uuid : String
[read-only] The unique id of this scope.
DefaultScope
Public Methods
 MethodDefined By
  
DefaultScope(context:Context, info:ScopeInfo, router:MessageRouter, domain:ApplicationDomain)
Creates a new instance.
DefaultScope
  
dispatchMessage(message:Object, selector:*):void
Dispatches a message through this scope.
DefaultScope
Property Detail
bindingManagerproperty
bindingManager:BindingManager  [read-only]

The manager for publishers and subscribers of the decoupled binding facility.


Implementation
    public function get bindingManager():BindingManager
commandManagerproperty 
commandManager:CommandManager  [read-only]

The manager for active asynchronous commands in this scope.


Implementation
    public function get commandManager():CommandManager
extensionsproperty 
extensions:ScopeExtensions  [read-only]

Custom extensions registered for this scope.


Implementation
    public function get extensions():ScopeExtensions
inheritedproperty 
inherited:Boolean  [read-only]

Indicates whether this scope will be inherited by child Contexts.


Implementation
    public function get inherited():Boolean
lifecycleObserversproperty 
lifecycleObservers:LifecycleObserverRegistry  [read-only]

The registry for observers of lifecycle events dispatched by objects within this scope.


Implementation
    public function get lifecycleObservers():LifecycleObserverRegistry
messageReceiversproperty 
messageReceivers:MessageReceiverRegistry  [read-only]

The registry for receivers of application messages dispatched through this scope.


Implementation
    public function get messageReceivers():MessageReceiverRegistry
nameproperty 
name:String  [read-only]

The name of the scope.


Implementation
    public function get name():String
persistenceManagerproperty 
persistenceManager:PersistenceManager  [read-only]

The manager for values persisted by publishers.


Implementation
    public function get persistenceManager():PersistenceManager
rootContextproperty 
rootContext:Context  [read-only]

The root Context of this scope.


Implementation
    public function get rootContext():Context
uuidproperty 
uuid:String  [read-only]

The unique id of this scope. In small or mid-size projects an id is often not needed, the framework will autogenerate the id in these cases and it can simply be ignored. In a big modular application there may be the need to address one particular scope within the system and the scheme of ids assigned to the scopes is often application-specific. The uid may be used to identify persistent published values or to explicitly route messages.


Implementation
    public function get uuid():String
Constructor Detail
DefaultScope()Constructor
public function DefaultScope(context:Context, info:ScopeInfo, router:MessageRouter, domain:ApplicationDomain)

Creates a new instance.

Parameters
context:Context — the Context this scope instance is associated with
 
info:ScopeInfo — the shared info for this scope, holding all scope-wide state like registered message receivers
 
router:MessageRouter — the message router to use for dispatching messages through this scope
 
domain:ApplicationDomain — the ApplicationDomain to use for reflection
Method Detail
dispatchMessage()method
public function dispatchMessage(message:Object, selector:*):void

Dispatches a message through this scope.

Parameters

message:Object — the message to dispatch
 
selector:* (default = NaN) — the selector to use if it cannot be determined from the message instance itself