|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectflex.management.ManageableComponent
flex.messaging.services.ServiceAdapter
flex.messaging.services.remoting.adapters.JavaAdapter
public class JavaAdapter
Basic adapter for invoking methods on a Java object. By default, it is stateless, in that a new object is instantiated for each request. If the destination configuration contains a stateful flag, the HTTP session is searched for an existing instance of the object, so multiple requests from the same client will be invoked on a stateful component.
Methods are cached, so requests subsequent to the initial creation/invocation will perform much better than will the initial invocation.
This class performs no internal synchronization.
| Field Summary | |
|---|---|
static String[] |
PROTECTED_PACKAGES
|
| Constructor Summary | |
|---|---|
JavaAdapter()
Constructs an unmanaged JavaAdapter instance. |
|
JavaAdapter(boolean enableManagement)
Constructs a JavaAdapter instance. |
|
| Method Summary | |
|---|---|
void |
addExcludeMethod(RemotingMethod value)
Adds a method to the list of excluded methods for the adapter. |
void |
addIncludeMethod(RemotingMethod value)
Adds a method to the list of included methods for the adapter. |
Iterator |
getExcludeMethodIterator()
Returns an Iterator over the currently registered exclude methods. |
Iterator |
getIncludeMethodIterator()
Returns an Iterator over the currently registered include methods. |
void |
initialize(String id,
ConfigMap properties)
Invoked to initialize the ManageableComponent. |
Object |
invoke(Message message)
Handle a data message intended for this adapter. |
void |
removeExcludeMethod(RemotingMethod value)
Removes a method from the list of excluded methods for the adapter. |
void |
removeIncludeMethod(RemotingMethod value)
Removes a method from the list of included methods for the adapter. |
void |
setDestination(Destination destination)
Casts the Destination into RemotingDestination
and calls super.setDestination. |
void |
start()
Starts the adapter if its associated Destination is started
and if the adapter is not already running. |
| Methods inherited from class flex.messaging.services.ServiceAdapter |
|---|
getAdapterState, getDestination, handlesSubscriptions, manage, setAdapterState, stop |
| Methods inherited from class flex.management.ManageableComponent |
|---|
getControl, getId, getParent, isManaged, isStarted, isValid, setControl, setId, setManaged, setParent |
| Methods inherited from class java.lang.Object |
|---|
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Field Detail |
|---|
public static final String[] PROTECTED_PACKAGES
| Constructor Detail |
|---|
public JavaAdapter()
JavaAdapter instance.
public JavaAdapter(boolean enableManagement)
JavaAdapter instance.
enableManagement - true if the JavaAdapter has a
corresponding MBean control for management; otherwise false.| Method Detail |
|---|
public void setDestination(Destination destination)
Destination into RemotingDestination
and calls super.setDestination.
setDestination in class ServiceAdapterdestination - remoting destination to associate with this adapterpublic Iterator getExcludeMethodIterator()
public void addExcludeMethod(RemotingMethod value)
value - method to excludepublic void removeExcludeMethod(RemotingMethod value)
value - method to remove from exlcuded methods listpublic Iterator getIncludeMethodIterator()
public void addIncludeMethod(RemotingMethod value)
value - method to includepublic void removeIncludeMethod(RemotingMethod value)
value - method to remove from the included methods list
public void initialize(String id,
ConfigMap properties)
ManageableComponent.
This base implementation calls setId() passing the provided
id and ignores the properties map argument.
Subclasses should call super.initialize().
initialize in interface FlexConfigurableinitialize in class ManageableComponentid - Id of the ManageableComponent.properties - Properties for the ManageableComponent.public void start()
Destination is started
and if the adapter is not already running. If subclasses override, they
must call super.start().
start in interface FlexComponentstart in class ServiceAdapterpublic Object invoke(Message message)
Typically the data content for the message is stored in the body property of the message. The headers of the message are used to store fields which relate to the transport of the message. The type of operation is stored as the operation property of the message.
invoke in class ServiceAdaptermessage - the message as sent by the client intended for this adapter
Message,
AsyncMessage
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
Send me an e-mail when comments are added to this page | Comment Report
Current page: http://livedocs.adobe.com/blazeds/1/javadoc/flex/messaging/services/remoting/adapters/JavaAdapter.html