|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectflex.management.ManageableComponent
flex.messaging.services.AbstractService
flex.messaging.services.MessageService
flex.data.DataService
public class DataService
This is the service which receives DataMessages and handles data synchronization functionality. It essentially adds DataMessage processing capabilities to the MessageService, so therefore it is a subclass of MessageService.
| Field Summary | |
|---|---|
static String |
LOG_CATEGORY
Log category for DataService. |
| Fields inherited from class flex.messaging.services.MessageService |
|---|
TIMING_LOG_CATEGORY |
| Fields inherited from class flex.messaging.services.AbstractService |
|---|
LOG_CATEGORY_STARTUP_DESTINATION |
| Fields inherited from interface flex.messaging.services.messaging.MessagingConstants |
|---|
ALLOW_SUBTOPICS_ELEMENT, BATCH_WRITE_SIZE_ELEMENT, CLUSTER_MESSAGE_ROUTING, DEFAULT_DURABLE_STORE, DEFAULT_MAX_CACHE_SIZE, DEFAULT_SUBTOPIC_SEPARATOR, DURABLE_STORE_TYPE_ELEMENT, IS_DURABLE_ELEMENT, MAX_CACHE_SIZE_ELEMENT, SUBTOPIC_SEPARATOR_ELEMENT, TIME_TO_LIVE_ELEMENT |
| Constructor Summary | |
|---|---|
DataService()
Constructs an unmanaged DataService. |
|
DataService(boolean enableManagement)
Constructs a DataService with the indicated management. |
|
| Method Summary | |
|---|---|
void |
addDestination(Destination destination)
Casts the Destination into DataDestination
and calls super.addDestination |
Destination |
createDestination(String id)
Creates a DataDestination instance, sets its id, sets it manageable
if the DataService that created it is manageable,
and sets its Service to the AbstractService that
created it. |
ConfigMap |
describeService(Endpoint endpoint)
Returns a ConfigMap of service properties that the client
needs. |
static flex.data.messages.DataMessage |
findCurrentCreateDataMessage(String messageId)
|
static Collection |
getPropertiesOnClientObject(Object clientObj)
Again, this belongs somewhere else and could be more efficient. |
static Object |
getPropertyOnClientObject(Object clientObj,
String propertyName)
|
static Object[] |
getUpdateBody(flex.data.messages.DataMessage toUpdate)
|
static Object |
getUpdateBody(flex.data.messages.DataMessage toUpdate,
int which)
|
static List |
getUpdateChanges(flex.data.messages.DataMessage update)
|
boolean |
getUseClusterBroadcast()
|
void |
initialize(String id,
ConfigMap properties)
Initializes the DataService with id and properties. |
void |
peerSyncAndPush(List messages)
This method is provided for a cluster peer broadcast, it is not invoked locally. |
void |
peerSyncAndPushOneToPeer(Message message,
Object remoteAddress)
Called from an external server when we are pushing messages individually using the manual message routing. |
void |
receiveAdapterState(String destinationId,
Object adapterState,
Object senderAddress)
This method is provided for a cluster peer broadcast, it is not invoked locally. |
void |
requestAdapterState(String destinationId,
Object requestingAddress)
This method is provided for a cluster peer broadcast, it is not invoked locally. |
void |
sendPeerSyncAndPush(List messages)
This method enables the service to invoke fellow service operations on other cluster nodes. |
Object |
serviceCommand(CommandMessage message)
Handles a command routed to the service by the MessageBroker. |
Object |
serviceMessage(Message message)
Processes messages of type DataMessage by invoking the
requested destination's adapter. |
static void |
setPropertyOnClientObject(Object clientObj,
String propertyName,
Object value)
|
static void |
setUpdateBody(flex.data.messages.DataMessage msg,
int which,
Object item)
|
void |
setUseClusterBroadcast(boolean ucb)
This controls whether destinations that are a part of this service broadcast their messages across the cluster. |
| Methods inherited from class flex.messaging.services.MessageService |
|---|
getSubscriberIds, initRemoteSubscriptions, pushMessageToClients, pushMessageToClients, sendPushMessageFromPeer, serviceMessageFromAdapter, start, subscribeFromPeer |
| Methods inherited from class flex.messaging.services.AbstractService |
|---|
addDefaultChannel, getDefaultAdapter, getDefaultChannels, getDestination, getDestination, getDestinations, getMessageBroker, getRegisteredAdapters, registerAdapter, removeDefaultChannel, removeDestination, setDefaultAdapter, setDefaultChannels, setId, setMessageBroker, stop, unregisterAdapter |
| Methods inherited from class flex.management.ManageableComponent |
|---|
getControl, getId, getParent, isManaged, isStarted, isValid, setControl, setManaged, setParent |
| Methods inherited from class java.lang.Object |
|---|
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Methods inherited from interface flex.messaging.services.Service |
|---|
getId |
| Methods inherited from interface flex.management.Manageable |
|---|
getControl, isManaged, setControl, setManaged |
| Methods inherited from interface flex.messaging.FlexComponent |
|---|
isStarted |
| Field Detail |
|---|
public static final String LOG_CATEGORY
DataService.
| Constructor Detail |
|---|
public DataService()
DataService.
public DataService(boolean enableManagement)
DataService with the indicated management.
enableManagement - true if the DataService
is manageable; otherwise false.| Method Detail |
|---|
public void initialize(String id,
ConfigMap properties)
DataService with id and properties.
initialize in interface FlexConfigurableinitialize in class ManageableComponentid - Id of the ManageableComponent.properties - Properties for the AbstractService.public Destination createDestination(String id)
DataDestination instance, sets its id, sets it manageable
if the DataService that created it is manageable,
and sets its Service to the AbstractService that
created it.
createDestination in interface ServicecreateDestination in class MessageServiceid - The id of the DataDestination.
Destination instanced created.public void addDestination(Destination destination)
Destination into DataDestination
and calls super.addDestination
addDestination in interface ServiceaddDestination in class MessageServicedestination - The Destination instance to be added.public void setUseClusterBroadcast(boolean ucb)
public boolean getUseClusterBroadcast()
public ConfigMap describeService(Endpoint endpoint)
ConfigMap of service properties that the client
needs. This includes service's id under "id" key and additional
DataService destination properties under "destination" key.
describeService in interface ServicedescribeService in class AbstractServiceendpoint - Endpoint used to filter the destinations of the service.
public void sendPeerSyncAndPush(List messages)
When this mode is disabled, we push messages individually across the cluster. In this mode, the destination's cluster-message-routing is used to determine whether to use broadcast or server-to-server modes.
public void peerSyncAndPushOneToPeer(Message message,
Object remoteAddress)
public void peerSyncAndPush(List messages)
public void requestAdapterState(String destinationId,
Object requestingAddress)
public void receiveAdapterState(String destinationId,
Object adapterState,
Object senderAddress)
public Object serviceCommand(CommandMessage message)
Service
serviceCommand in interface ServiceserviceCommand in class MessageServicemessage - The message sent by the MessageBrokerpublic Object serviceMessage(Message message)
DataMessage by invoking the
requested destination's adapter.
serviceMessage in interface ServiceserviceMessage in class MessageServicemessage - The message sent by the MessageBroker
public static Object getUpdateBody(flex.data.messages.DataMessage toUpdate,
int which)
public static Object[] getUpdateBody(flex.data.messages.DataMessage toUpdate)
public static List getUpdateChanges(flex.data.messages.DataMessage update)
public static void setUpdateBody(flex.data.messages.DataMessage msg,
int which,
Object item)
public static flex.data.messages.DataMessage findCurrentCreateDataMessage(String messageId)
public static Object getPropertyOnClientObject(Object clientObj,
String propertyName)
public static void setPropertyOnClientObject(Object clientObj,
String propertyName,
Object value)
public static Collection getPropertiesOnClientObject(Object clientObj)
|
||||||||||
| 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/livecycle/es/sdkHelp/programmer/lcdsjavadoc/flex/data/DataService.html