|
NextApp Echo3 v3.0.b4 |
||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object nextapp.echo.webcontainer.AbstractComponentSynchronizePeer
public abstract class AbstractComponentSynchronizePeer
Default abstract implementation of ComponentSynchronizePeer
.
Provides implementations of all methods less getComponentClass()
.
Determines properties to render to client by querying a Component
's
local style and using a ComponentIntrospector
to determine whether
those properties
Nested Class Summary | |
---|---|
static class |
AbstractComponentSynchronizePeer.EventPeer
Peer for synchronizing events between client and server. |
Constructor Summary | |
---|---|
AbstractComponentSynchronizePeer()
Default constructor. |
Method Summary | |
---|---|
void |
addEvent(AbstractComponentSynchronizePeer.EventPeer eventPeer)
Adds an EventPeer to process client-side events. |
void |
addOutputProperty(java.lang.String propertyName)
Adds a non-indexed output property. |
void |
addOutputProperty(java.lang.String propertyName,
boolean indexed)
Adds an output property. |
void |
addRequiredComponentClass(java.lang.Class componentClass)
Adds a required component class that must also be initialized before this component can be rendered. |
abstract java.lang.Class |
getComponentClass()
Returns the (most basic) supported component class. |
java.lang.Class |
getEventDataClass(java.lang.String eventType)
Returns null. |
java.util.Iterator |
getEventTypes(nextapp.echo.app.util.Context context,
nextapp.echo.app.Component component)
Returns an iterator of String s containing all event types registered using addEvent() . |
java.lang.Class |
getInputPropertyClass(java.lang.String propertyName)
Returns null. |
java.lang.Object |
getOutputProperty(nextapp.echo.app.util.Context context,
nextapp.echo.app.Component component,
java.lang.String propertyName,
int propertyIndex)
Returns any property from the local style of the Component . |
java.util.Iterator |
getOutputPropertyIndices(nextapp.echo.app.util.Context context,
nextapp.echo.app.Component component,
java.lang.String propertyName)
Returns the indices of any indexed property from the local style of the Component . |
java.lang.String |
getOutputPropertyMethodName(nextapp.echo.app.util.Context context,
nextapp.echo.app.Component component,
java.lang.String propertyName)
Returns null. |
java.util.Iterator |
getOutputPropertyNames(nextapp.echo.app.util.Context context,
nextapp.echo.app.Component component)
Returns the names of all properties currently set in the component's local Style ,
in addition to any properties added by invoking addOutputProperty() . |
java.util.Iterator |
getUpdatedOutputPropertyNames(nextapp.echo.app.util.Context context,
nextapp.echo.app.Component component,
nextapp.echo.app.update.ServerComponentUpdate update)
Returns property names that have been updated in the specified ServerComponentUpdate that are either part of the local style
or have been added via the addOutputProperty() method. |
boolean |
hasListeners(nextapp.echo.app.util.Context context,
nextapp.echo.app.Component component,
java.lang.String eventType)
Determines if the specified component has any listeners registered of the specified event type. |
boolean |
hasUpdatedListeners(nextapp.echo.app.util.Context context,
nextapp.echo.app.Component component,
nextapp.echo.app.update.ServerComponentUpdate update,
java.lang.String eventType)
Determines if any server-side listeners for a specific client-side event type have been added or removed in the specified ServerComponentUpdate . |
void |
init(nextapp.echo.app.util.Context context,
nextapp.echo.app.Component component)
Invokes the init() methods of peers of required component classes (added via addRequiredComponentClass()). |
boolean |
isOutputPropertyIndexed(nextapp.echo.app.util.Context context,
nextapp.echo.app.Component component,
java.lang.String propertyName)
Determines if a local style property or additional property (added via addOutputProperty() )
is indexed. |
boolean |
isOutputPropertyReferenced(nextapp.echo.app.util.Context context,
nextapp.echo.app.Component component,
java.lang.String propertyName)
Returns true for any property set as rendered-by-reference via the setOutputPropertyReferenced() method. |
void |
processEvent(nextapp.echo.app.util.Context context,
nextapp.echo.app.Component component,
java.lang.String eventType,
java.lang.Object eventData)
Does nothing. |
void |
setOutputPropertyReferenced(java.lang.String propertyName,
boolean newValue)
Sets the rendered-by-reference state of a property. |
void |
storeInputProperty(nextapp.echo.app.util.Context context,
nextapp.echo.app.Component component,
java.lang.String propertyName,
int index,
java.lang.Object newValue)
Does nothing. |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Methods inherited from interface nextapp.echo.webcontainer.ComponentSynchronizePeer |
---|
getClientComponentType |
Constructor Detail |
---|
public AbstractComponentSynchronizePeer()
Method Detail |
---|
public void addEvent(AbstractComponentSynchronizePeer.EventPeer eventPeer)
EventPeer
to process client-side events.
eventPeer
- the EventPeer
to addpublic void addOutputProperty(java.lang.String propertyName)
addOutputProperty(java.lang.String, boolean)
public void addOutputProperty(java.lang.String propertyName, boolean indexed)
getOutputPropertyName()
method of this class.
If the indexed flag is set, the isOutputPropertyIndexed
method will also return true for this property name
propertyName
- the property name to addindexed
- a flag indicating whether the property is indexedpublic void addRequiredComponentClass(java.lang.Class componentClass)
componentClass
- public abstract java.lang.Class getComponentClass()
getComponentClass
in interface ComponentSynchronizePeer
public java.lang.Class getEventDataClass(java.lang.String eventType)
getEventDataClass
in interface ComponentSynchronizePeer
eventType
- the type of the event
Class
ComponentSynchronizePeer.getEventDataClass(java.lang.String)
public java.util.Iterator getEventTypes(nextapp.echo.app.util.Context context, nextapp.echo.app.Component component)
String
s containing all event types registered using addEvent()
.
getEventTypes
in interface ComponentSynchronizePeer
context
- the relevant Context
, provides
standard contextual information described in class description, in
addition to the following:
component
- the Component
being rendered
Iterator
over a collection of String
s
of the remote client event type namesComponentSynchronizePeer.getEventTypes(Context, Component)
public java.lang.Object getOutputProperty(nextapp.echo.app.util.Context context, nextapp.echo.app.Component component, java.lang.String propertyName, int propertyIndex)
Component
.
Implementations should override if they wish to support additional properties.
getOutputProperty
in interface ComponentSynchronizePeer
context
- the relevant Context
, provides
standard contextual information described in class description, in
addition to the following:
component
- the Component
being renderedpropertyName
- the name of the property being renderedpropertyIndex
- the property index (only relevant for indexed properties, -1 will
be provided for non-indexed properties)
ComponentSynchronizePeer.getOutputProperty(nextapp.echo.app.util.Context,
nextapp.echo.app.Component, java.lang.String, int)
public java.util.Iterator getOutputPropertyIndices(nextapp.echo.app.util.Context context, nextapp.echo.app.Component component, java.lang.String propertyName)
Component
.
Implementations should override if they wish to support additional properties.
getOutputPropertyIndices
in interface ComponentSynchronizePeer
context
- the relevant Context
, provides
standard contextual information described in class description, in
addition to the following:
component
- the componentpropertyName
- the property name
Iterator
that returns the set indices in
incrementing order as Integer
sComponentSynchronizePeer.getOutputPropertyIndices(nextapp.echo.app.util.Context,
nextapp.echo.app.Component, java.lang.String)
public java.lang.String getOutputPropertyMethodName(nextapp.echo.app.util.Context context, nextapp.echo.app.Component component, java.lang.String propertyName)
getOutputPropertyMethodName
in interface ComponentSynchronizePeer
context
- the relevant Context
, provides
standard contextual information described in class description, in
addition to the following:
component
- the componentpropertyName
- the property name
ComponentSynchronizePeer.getOutputPropertyMethodName(
nextapp.echo.app.util.Context, nextapp.echo.app.Component, java.lang.String)
public java.util.Iterator getOutputPropertyNames(nextapp.echo.app.util.Context context, nextapp.echo.app.Component component)
Style
,
in addition to any properties added by invoking addOutputProperty()
.
getOutputPropertyNames
in interface ComponentSynchronizePeer
context
- the relevant Context
, provides
standard contextual information described in class description, in
addition to the following:
component
- the component
Iterator
of property namesComponentSynchronizePeer.getOutputPropertyNames(Context, nextapp.echo.app.Component)
public java.lang.Class getInputPropertyClass(java.lang.String propertyName)
getInputPropertyClass
in interface ComponentSynchronizePeer
propertyName
- the name of the property
Class
ComponentSynchronizePeer.getInputPropertyClass(java.lang.String)
public java.util.Iterator getUpdatedOutputPropertyNames(nextapp.echo.app.util.Context context, nextapp.echo.app.Component component, nextapp.echo.app.update.ServerComponentUpdate update)
ServerComponentUpdate
that are either part of the local style
or have been added via the addOutputProperty()
method.
getUpdatedOutputPropertyNames
in interface ComponentSynchronizePeer
context
- the relevant Context
, provides
standard contextual information described in class description, in
addition to the following:
component
- the componentupdate
- the ServerComponentUpdate
being rendered
Iterator
of property names to update on the clientComponentSynchronizePeer.getUpdatedOutputPropertyNames(nextapp.echo.app.util.Context,
nextapp.echo.app.Component,
nextapp.echo.app.update.ServerComponentUpdate)
public boolean hasListeners(nextapp.echo.app.util.Context context, nextapp.echo.app.Component component, java.lang.String eventType)
ComponentSynchronizePeer
hasListeners
in interface ComponentSynchronizePeer
context
- the relevant Context
, provides
standard contextual information described in class description, in
addition to the following:
component
- the componenteventType
- the client-side event type
ComponentSynchronizePeer.hasListeners(nextapp.echo.app.util.Context,
nextapp.echo.app.Component, java.lang.String)
public boolean hasUpdatedListeners(nextapp.echo.app.util.Context context, nextapp.echo.app.Component component, nextapp.echo.app.update.ServerComponentUpdate update, java.lang.String eventType)
ComponentSynchronizePeer
ServerComponentUpdate
.
hasUpdatedListeners
in interface ComponentSynchronizePeer
context
- the relevant Context
, provides
standard contextual information described in class description, in
addition to the following:
component
- the componentupdate
- the ServerComponentUpdate
to processeventType
- the client-side event
ComponentSynchronizePeer.hasUpdatedListeners(nextapp.echo.app.util.Context,
nextapp.echo.app.Component, nextapp.echo.app.update.ServerComponentUpdate, java.lang.String)
public void init(nextapp.echo.app.util.Context context, nextapp.echo.app.Component component)
init
in interface ComponentSynchronizePeer
context
- the relevant Context
, provides
standard contextual information described in class description, in
addition to the following:
component
- the component being renderedComponentSynchronizePeer.init(Context, Component)
public boolean isOutputPropertyIndexed(nextapp.echo.app.util.Context context, nextapp.echo.app.Component component, java.lang.String propertyName)
addOutputProperty()
)
is indexed.
isOutputPropertyIndexed
in interface ComponentSynchronizePeer
context
- the relevant Context
, provides
standard contextual information described in class description, in
addition to the following:
component
- the componentpropertyName
- the property name
ComponentSynchronizePeer.isOutputPropertyIndexed(nextapp.echo.app.util.Context,
nextapp.echo.app.Component, java.lang.String)
public boolean isOutputPropertyReferenced(nextapp.echo.app.util.Context context, nextapp.echo.app.Component component, java.lang.String propertyName)
setOutputPropertyReferenced()
method.
isOutputPropertyReferenced
in interface ComponentSynchronizePeer
context
- the relevant Context
, provides
standard contextual information described in class description, in
addition to the following:
component
- the componentpropertyName
- the property name
ComponentSynchronizePeer.isOutputPropertyReferenced(
nextapp.echo.app.util.Context, nextapp.echo.app.Component, java.lang.String)
public void processEvent(nextapp.echo.app.util.Context context, nextapp.echo.app.Component component, java.lang.String eventType, java.lang.Object eventData)
processEvent
in interface ComponentSynchronizePeer
context
- the relevant Context
, provides
standard contextual information described in class description, in
addition to the following:
ClientMessage
ClientUpdateManager
component
- the updated Component
eventType
- the type of the eventeventData
- arbitrary component/event-specific event-related dataComponentSynchronizePeer.processEvent(nextapp.echo.app.util.Context,
nextapp.echo.app.Component, java.lang.String, java.lang.Object)
public void setOutputPropertyReferenced(java.lang.String propertyName, boolean newValue)
isOutputPropertyReferenced
will return true for any property set as
referenced using this method.
propertyName
- the propertyNamenewValue
- true if the property should be rendered by referenceComponentSynchronizePeer.isOutputPropertyReferenced(
nextapp.echo.app.util.Context, nextapp.echo.app.Component, java.lang.String)
public void storeInputProperty(nextapp.echo.app.util.Context context, nextapp.echo.app.Component component, java.lang.String propertyName, int index, java.lang.Object newValue)
storeInputProperty
in interface ComponentSynchronizePeer
context
- the relevant Context
, provides
standard contextual information described in class description, in
addition to the following:
ClientMessage
ClientUpdateManager
component
- the updated Component
propertyName
- the name of the propertyindex
- the index of the property
(or -1 in the typical case of a non-indexed property)newValue
- the new value of the propertyComponentSynchronizePeer.storeInputProperty(nextapp.echo.app.util.Context,
nextapp.echo.app.Component, java.lang.String, int, java.lang.Object)
|
NextApp Echo3 v3.0.b4 |
||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |