|
xmlBlaster 1.6.2 client API | ||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||||
java.lang.Objectorg.xmlBlaster.client.protocol.AbstractCallbackExtended
org.xmlBlaster.client.XmlBlasterAccess
This is the default implementation of the java client side remote access to xmlBlaster.
It hides a client side queue, the client side dispatcher framework for polling or pinging the server and some more features.
The interface I_CallbackRaw/I_Callback/I_CallbackExtenden are enforced by AbstractCallbackExtended.
| Field Summary |
| Fields inherited from class org.xmlBlaster.client.protocol.AbstractCallbackExtended |
glob, updateBulkAck |
| Constructor Summary | |
XmlBlasterAccess(Global glob)
Create an xmlBlaster accessor. |
|
XmlBlasterAccess(java.lang.String[] args)
Create an xmlBlaster accessor. |
|
| Method Summary | |
ConnectReturnQos |
connect(ConnectQos qos,
I_Callback updateListener)
Login to xmlBlaster. |
ConnectReturnQos |
connect(ConnectQos qos,
I_StreamingCallback streamingUpdateListener,
boolean withQueue)
|
SynchronousCache |
createSynchronousCache(int size)
Setup the cache mode. |
PublishReturnQos |
createTemporaryTopic(long destroyDelay,
int historyMaxMsg)
|
PublishReturnQos |
createTemporaryTopic(TopicProperty topicProperty)
Create a temporay topic. |
boolean |
disconnect(DisconnectQos disconnectQos)
Logout from the server. |
EraseReturnQos[] |
erase(EraseKey eraseKey,
EraseQos eraseQos)
|
EraseReturnQos[] |
erase(java.lang.String xmlKey,
java.lang.String qos)
|
MsgUnit[] |
get(GetKey getKey,
GetQos getQos)
Get synchronous messages. |
MsgUnit[] |
get(java.lang.String xmlKey,
java.lang.String qos)
|
java.lang.String |
getBuildJavaVendor()
The java vendor of the compiler. |
java.lang.String |
getBuildJavaVersion()
The compiler java version. |
java.lang.String |
getBuildTimestamp()
Returns the date when xmlBlaster client library was compiled. |
MsgUnit[] |
getCached(GetKey getKey,
GetQos getQos)
Access synchronously messages. |
I_CallbackServer |
getCbServer()
Access the callback server. |
java.lang.String |
getConnectionQueueId()
Access the unique id of my client side queue. |
long |
getConnectionQueueMaxMsgs()
How many messages are max. |
long |
getConnectionQueueNumMsgs()
How many messages are in this client side queue |
java.lang.String |
getConnectionState()
Get the connection state. |
ConnectQos |
getConnectQos()
Access the current ConnectQos |
ConnectReturnQos |
getConnectReturnQos()
Access the returned QoS of a connect() call. |
ContextNode |
getContextNode()
The unique name of this session instance. |
boolean |
getDispatcherActive()
Access the dispatcher state. |
DispatchStatistic |
getDispatchStatistic()
Access the statistic holder. |
FileDumper |
getFileDumper()
|
Global |
getGlobal()
Access the environment settings of this connection. |
java.lang.String |
getId()
Create a descriptive ME, for logging only |
java.lang.String |
getLogId()
Useful as a logging prefix. |
java.lang.String |
getLoginDate()
Get date when client logged in. |
java.lang.String |
getLoginName()
Access the login name. |
long |
getNumErase()
How many subscribe requests where send by this clients login session |
long |
getNumGet()
How many get requests where send by this clients login session |
long |
getNumPublish()
How many messages where send by this clients login session |
long |
getNumSubscribe()
How many subscribe requests where send by this clients login session |
long |
getNumUnSubscribe()
How many unsubscribe requests where send by this clients login session |
long |
getNumUpdate()
How many messages where received by this clients login session |
long |
getNumUpdateOneway()
How many oneway messages where received by this clients login session |
long |
getPingRoundTripDelay()
Measures the round trip for the last ping() invocation in milli seconds. |
static java.lang.String |
getPluginUsage(java.lang.String clazzName)
Access plugin specific usage() |
long |
getPublicSessionId()
Get the sessions public session id. |
I_Queue |
getQueue()
Enforced by interface I_ConnectionHandler |
java.lang.String |
getRevisionNumber()
Returns the xmlBlaster client library SVN version control revision number. |
long |
getRoundTripDelay()
Measures the round trip for the last remote method invocation in milli seconds. |
org.xmlBlaster.authentication.plugins.I_ClientPlugin |
getSecurityPlugin()
Access the client side security plugin. |
java.lang.String |
getServerNodeId()
The cluster node id (name) to which we want to connect. |
SessionName |
getSessionName()
The public session ID of this login session. |
ConnectionStateEnum |
getState()
Enforced by interface I_ConnectionHandler |
java.lang.String |
getStorageIdStr()
|
I_Callback |
getUpdateListener()
The implementation which receives the callback messages. |
long |
getUptime()
Uptime in seconds |
java.lang.String |
getVersion()
Get the xmlBlaster client library version number. |
I_CallbackServer |
initCbServer(java.lang.String loginName,
CallbackAddress callbackAddress)
Create a new instance of the desired protocol driver like CORBA or RMI driver using the plugin loader. |
java.lang.String[] |
invokeErase(java.lang.String url,
java.lang.String qos)
JMX |
java.lang.String[] |
invokeGet(java.lang.String url,
java.lang.String qos)
JMX |
java.lang.String |
invokePublish(java.lang.String key,
java.lang.String content,
java.lang.String qos)
JMX |
java.lang.String |
invokeSubscribe(java.lang.String url,
java.lang.String qos)
JMX |
java.lang.String[] |
invokeUnSubscribe(java.lang.String url,
java.lang.String qos)
JMX |
boolean |
isAlive()
Enforced by interface I_ConnectionHandler |
boolean |
isCallbackConfigured()
Check if a callback was configured, if client has passed a callback address on connect. |
boolean |
isCallbackDispatcherActive()
|
boolean |
isConnected()
Has the connect() method successfully passed? |
boolean |
isDead()
Enforced by interface I_ConnectionHandler |
boolean |
isPolling()
Enforced by interface I_ConnectionHandler |
boolean |
isShutdown()
|
void |
leaveServer(java.util.Map map)
Leaves the connection to the server and cleans up the client side resources without making a server side disconnect. |
static void |
main(java.lang.String[] args)
For testing invoke: java org.xmlBlaster.client.XmlBlasterAccess |
java.lang.String[] |
peekClientMessages(int numOfEntries)
Peek messages from client queue, they are not removed |
java.lang.String[] |
peekClientMessagesToFile(int numOfEntries,
java.lang.String path)
Peek messages from client queue and dump them to a file, they are not removed. |
void |
postSend(MsgQueueEntry[] entries)
Called after a messages is send from the client side queue, but not for oneway messages. |
PublishReturnQos |
publish(MsgUnit msgUnit)
|
PublishReturnQos[] |
publishArr(MsgUnit[] msgUnitArr)
|
void |
publishOneway(MsgUnit[] msgUnitArr)
Publish messages. |
PublishReturnQos[] |
publishStream(java.io.InputStream is,
MsgKeyData keyData,
MsgQosData qosData,
int maxBufSize,
I_ReplaceContent contentReplacer)
Publishes one message in streaming manner, if the message content is too big to fit in one single chunk, the message is split in several smaller messages (called chunks) and these are published. |
MsgUnit[] |
receive(java.lang.String oid,
int maxEntries,
long timeout,
boolean consumable)
This method synchronously accesses maxEntries messages from any xmlBlaster server side queue. |
void |
refreshSession()
Send an event to xmlBlaster to refresh the login session life time. |
void |
registerConnectionListener(I_ConnectionStateListener connectionListener)
Register a listener to get events about connection status changes. |
I_PostSendListener |
registerPostSendListener(I_PostSendListener postSendListener)
Register a listener to get notifications when a messages is successfully send from the client side tail back queue. |
MsgUnit[] |
request(MsgUnit msgUnit,
long timeout,
int maxEntries)
Implements the blocking request/reply pattern. |
java.lang.String |
sendAdministrativeCommand(java.lang.String command)
Convenience method to send an administrative command to xmlBlaster. |
boolean |
sendingFailed(MsgQueueEntry[] entries,
XmlBlasterException exception)
Called if an asynchronous message is rejected by the server. |
void |
setCallbackDispatcherActive(boolean activate)
Switch callback dispatcher on/off. |
void |
setClientErrorHandler(I_MsgErrorHandler msgErrorHandler)
Use a specific error handler instead of the default one. |
void |
setDispatcherActive(boolean dispatcherActive)
Sets the DispachManager belonging to this session to active or inactive. |
void |
setServerNodeId(java.lang.String nodeId)
Allows to set the node name for nicer logging. |
void |
setStorageIdStr(java.lang.String prefix)
Allows to set a unique client side queue name (connection queue). |
void |
setUpdateListener(I_Callback updateListener)
Register a listener to receive the callback messages. |
SubscribeReturnQos |
subscribe(java.lang.String xmlKey,
java.lang.String qos)
|
SubscribeReturnQos |
subscribe(java.lang.String xmlKey,
java.lang.String qos,
I_Callback cb)
Subscribe to messages. |
SubscribeReturnQos |
subscribe(SubscribeKey subscribeKey,
SubscribeQos subscribeQos)
Subscribe to messages. |
SubscribeReturnQos |
subscribe(SubscribeKey subscribeKey,
SubscribeQos subscribeQos,
I_Callback cb)
This subscribe variant allows to specify a specialized callback for updated messages. |
void |
toAlive(DispatchManager dispatchManager,
ConnectionStateEnum oldState)
Call by DispatchManager on connection state transition. |
void |
toDead(DispatchManager dispatchManager,
ConnectionStateEnum oldState,
java.lang.String errorText)
Call by DispatchManager on connection state transition. |
void |
toPolling(DispatchManager dispatchManager,
ConnectionStateEnum oldState)
Call by DispatchManager on connection state transition. |
java.lang.String |
toXml()
Dump state of this object into a XML ASCII string. |
java.lang.String |
toXml(java.lang.String extraOffset)
Dump state of this object into a XML ASCII string. |
UnSubscribeReturnQos[] |
unSubscribe(java.lang.String xmlKey,
java.lang.String qos)
|
UnSubscribeReturnQos[] |
unSubscribe(UnSubscribeKey unSubscribeKey,
UnSubscribeQos unSubscribeQos)
Cancel subscription. |
java.lang.String |
update(java.lang.String cbSessionId,
UpdateKey updateKey,
byte[] content,
UpdateQos updateQos)
This is the callback method invoked from xmlBlaster delivering us a new asynchronous message. |
static java.lang.String |
usage(Global glob)
Command line usage. |
| Methods inherited from class org.xmlBlaster.client.protocol.AbstractCallbackExtended |
update, update, updateOneway, updateOneway |
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
public XmlBlasterAccess(Global glob)
import org.xmlBlaster.util.Global; ... final Global glob = new Global(args); final I_XmlBlasterAccess xmlBlasterAccess = glob.getXmlBlasterAccess();
glob - Your environment handle or null to use the default Global.instance()
You must use a cloned Global for each XmlBlasterAccess created.
engine.Global is not allowed here, only util.Global is supported
java.lang.IllegalArgumentException - If engine.Global is used as parameterpublic XmlBlasterAccess(java.lang.String[] args)
final Global glob = new Global(args); final I_XmlBlasterAccess xmlBlasterAccess = glob.getXmlBlasterAccess();
args - Your command line arguments| Method Detail |
public void registerConnectionListener(I_ConnectionStateListener connectionListener)
I_XmlBlasterAccess
registerConnectionListener in interface I_XmlBlasterAccessconnectionListener - null or your listener implementation on connection state changes (ALIVE | POLLING | DEAD)I_XmlBlasterAccess.registerConnectionListener(I_ConnectionStateListener)public final I_PostSendListener registerPostSendListener(I_PostSendListener postSendListener)
registerPostSendListener in interface I_XmlBlasterAccesspostSendListener - The postSendListener to set.
public final void postSend(MsgQueueEntry[] entries)
postSend in interface I_PostSendListener
public boolean sendingFailed(MsgQueueEntry[] entries,
XmlBlasterException exception)
I_PostSendListenerIf the server e.g. throws an IllegalArgument back to the client the message will most probably never succeed and retrying to send the message makes no sense. You can intercept this case here and eliminate the message.
ErrorCodes of type "communication.*" are not reported here as the dispatcher framework automatically handles reconnect and retry.
NOTE: For ErrorCodes of type "authentication.*" the connection will go to DEAD and the connection queue entries remain for pubSessionId>0. For pubSessionId<0 (none fail safe) the queue entries are removed (to be implemented TODO).
sendingFailed in interface I_PostSendListenerentries - Each MsgQueueEntry includes the returned QoSexception - The cause
public FileDumper getFileDumper()
throws XmlBlasterException
XmlBlasterExceptionpublic SynchronousCache createSynchronousCache(int size)
I_XmlBlasterAccess
createSynchronousCache in interface I_XmlBlasterAccesssize - Size of the cache. This number specifies the count of subscriptions the cache
can hold. It specifies NOT the number of messages.
I_XmlBlasterAccess.getCached(GetKey, GetQos),
client.cache requirementpublic void setClientErrorHandler(I_MsgErrorHandler msgErrorHandler)
I_XmlBlasterAccess
setClientErrorHandler in interface I_XmlBlasterAccessmsgErrorHandler - Your implementation of the error handler.ClientErrorHandlerpublic java.lang.String getConnectionQueueId()
XmlBlasterAccessMBean
getConnectionQueueId in interface XmlBlasterAccessMBeanpublic final ContextNode getContextNode()
public ConnectReturnQos connect(ConnectQos qos,
I_StreamingCallback streamingUpdateListener,
boolean withQueue)
throws XmlBlasterException
XmlBlasterException
public ConnectReturnQos connect(ConnectQos qos,
I_Callback updateListener)
throws XmlBlasterException
I_XmlBlasterAccessConnecting with the default configuration (which checks xmlBlaster.properties and your command line arguments):
import org.xmlBlaster.util.Global; ... I_XmlBlasterAccess xmlBlasterAccess = glob.getXmlBlasterAccess(); xmlBlasterAccess.connect(null, null);
The default behavior is to poll automatically for the server if it is not found. As we have not specified a listener for returned messages from the server there is no callback server created.
This example shows how to configure different behavior:
// Example how to configure fail safe settings
ConnectQos connectQos = new ConnectQos(glob);
Address address = new Address(glob);
address.setDelay(4000L); // retry connecting every 4 sec
address.setRetries(-1); // -1 == forever
address.setPingInterval(0L); // switched off
addr.setType("SOCKET"); // don't use CORBA protocol, but use SOCKET instead
connectQos.setAddress(address);
CallbackAddress cbAddress = new CallbackAddress(glob);
cbAddress.setDelay(4000L); // retry connecting every 4 sec
cbAddress.setRetries(-1); // -1 == forever
cbAddress.setPingInterval(4000L); // ping every 4 seconds
connectQos.addCallbackAddress(cbAddress);
xmlBlasterAccess.connect(connectQos, new I_Callback() {
public String update(String cbSessionId, UpdateKey updateKey, byte[] content,
UpdateQos updateQos) {
if (updateKey.isInternal()) {
return "";
}
if (updateQos.isErased()) {
return "";
}
log.info(ME, "Receiving asynchronous message '" + updateKey.getOid() +
"' state=" + updateQos.getState() + " in default handler");
return "";
}
}); // Login to xmlBlaster, default handler for updates;
connect in interface I_XmlBlasterAccessqos - Your configuration desireupdateListener - If not null a callback server will be created and
callback messages will be routed to your updateListener.update() method.
XmlBlasterException - only if connection state is DEAD, typically thrown on wrong configurations.
You must call connect again with different settings.I_XmlBlasterAccess.connect(ConnectQos, I_Callback)public boolean isConnected()
I_XmlBlasterAccessNote that this contains no information about the current connection state of the protocol layer.
isConnected in interface I_XmlBlasterAccessI_ConnectionHandler.isAlive(),
I_ConnectionHandler.isPolling(),
I_ConnectionHandler.isDead()
public void refreshSession()
throws XmlBlasterException
I_XmlBlasterAccess
refreshSession in interface I_XmlBlasterAccessXmlBlasterException - like ErrorCode.USER_NOT_CONNECTED and othersI_XmlBlasterAccess.refreshSession()
public I_CallbackServer initCbServer(java.lang.String loginName,
CallbackAddress callbackAddress)
throws XmlBlasterException
I_XmlBlasterAccessNote that the returned instance is of your control only, we don't cache it in any way, this method is only a helper hiding the plugin loading.
initCbServer in interface I_XmlBlasterAccessloginName - A nice name for logging purposescallbackAddress - The callback address configuration, contains for example
type like "IOR" or "RMI" and version of the driver, e.g. "1.0"
XmlBlasterExceptionI_XmlBlasterAccess.initCbServer(String, CallbackAddress)public org.xmlBlaster.authentication.plugins.I_ClientPlugin getSecurityPlugin()
I_XmlBlasterAccess
getSecurityPlugin in interface I_XmlBlasterAccessgetSecurityPlugin in class AbstractCallbackExtendedpublic boolean disconnect(DisconnectQos disconnectQos)
I_XmlBlasterAccessleaveServer(null)
and throw the xmlBlasterAccess instance away.
This is often the case if the client disappears and at a later point wants
to reconnect. On server side the queue for this session remains alive and
collects messages.
If '-dispatch/connection/doSendConnect false' was set call disconnect() nevertheless
to cleanup client side resources.
disconnect in interface I_XmlBlasterAccessdisconnectQos - Describe the desired behavior on disconnect
I_XmlBlasterAccess.disconnect(DisconnectQos),
interface.disconnect requirementpublic void leaveServer(java.util.Map map)
I_XmlBlasterAccessAs the login session on server side stays alive, all subscriptions stay valid and callback messages are queued by the server. If you connect at a later time the server sends us all queued messages.
Once you have called this method the I_XmlBlasterAccess becomes invalid and any further invocation results in an XmlBlasterException to be thrown.
leaveServer in interface I_XmlBlasterAccessmap - The properties to pass while leaving server.
Currently this argument has no effect. You can
pass null as a parameter.I_XmlBlasterAccess.leaveServer(Map)public boolean isShutdown()
public I_CallbackServer getCbServer()
getCbServer in interface I_XmlBlasterAccessI_XmlBlasterAccess.connect(ConnectQos, I_Callback)public java.lang.String getId()
getId in interface I_XmlBlasterAccesspublic java.lang.String getLogId()
public SessionName getSessionName()
getSessionName in interface I_XmlBlasterAccesspublic java.lang.String getStorageIdStr()
getStorageIdStr in interface I_XmlBlasterAccessI_XmlBlasterAccess.getStorageIdStr()public void setStorageIdStr(java.lang.String prefix)
I_XmlBlasterAccess
setStorageIdStr in interface I_XmlBlasterAccessprefix - For example "toserver1"+sessionName.getRelativeName()I_XmlBlasterAccess.setStorageIdStr(String)public void setServerNodeId(java.lang.String nodeId)
setServerNodeId in interface I_XmlBlasterAccessnodeId - For example "/xmlBlaster/node/heron"public java.lang.String getServerNodeId()
getServerNodeId in interface I_XmlBlasterAccess
public SubscribeReturnQos subscribe(java.lang.String xmlKey,
java.lang.String qos)
throws XmlBlasterException
subscribe in interface I_XmlBlasterXmlBlasterExceptionI_XmlBlasterAccess.subscribe(SubscribeKey, SubscribeQos)
public SubscribeReturnQos subscribe(SubscribeKey subscribeKey,
SubscribeQos subscribeQos)
throws XmlBlasterException
I_XmlBlasterAccessThe messages are delivered asynchronous with the update() method.
subscribe in interface I_XmlBlasterAccesssubscribeKey - Which message topics to retrievesubscribeQos - Control the behavior and further filter messages with mime based filter plugins
XmlBlasterException - like ErrorCode.USER_NOT_CONNECTED and othersI_XmlBlasterAccess.subscribe(SubscribeKey, SubscribeQos)
public SubscribeReturnQos subscribe(java.lang.String xmlKey,
java.lang.String qos,
I_Callback cb)
throws XmlBlasterException
I_XmlBlasterAccess
subscribe in interface I_XmlBlasterAccessxmlKey - Which message topics to retrieveqos - Control the behavior and further filter messages with mime based filter plugins
XmlBlasterException - like ErrorCode.USER_NOT_CONNECTED and othersI_XmlBlasterAccess.subscribe(SubscribeKey, SubscribeQos, I_Callback)
public SubscribeReturnQos subscribe(SubscribeKey subscribeKey,
SubscribeQos subscribeQos,
I_Callback cb)
throws XmlBlasterException
I_XmlBlasterAccess
XmlBlasterAccess con = ... // login etc.
...
SubscribeKey key = new SubscribeKey(glob, "//stock", "XPATH");
SubscribeQos qos = new SubscribeQos(glob);
try {
con.subscribe(key, qos, new I_Callback() {
public String update(String name, UpdateKey updateKey, byte[] content, UpdateQos updateQos) {
System.out.println("Receiving message for '//stock' subscription ...");
return "";
}
});
} catch(XmlBlasterException e) {
System.out.println(e.getMessage());
}
NOTE: You need to pass a callback handle on login as well (even if you
never use it). It allows to setup the callback server and is the
default callback deliver channel for PtP messages.
NOTE: On logout we automatically unSubscribe() this subscription
if not done before.
subscribe in interface I_XmlBlasterAccesscb - Your callback handling implementation
XmlBlasterException - like ErrorCode.USER_NOT_CONNECTED and othersI_XmlBlasterAccess.subscribe(SubscribeKey, SubscribeQos, I_Callback)
public MsgUnit[] get(java.lang.String xmlKey,
java.lang.String qos)
throws XmlBlasterException
get in interface I_XmlBlasterXmlBlasterExceptionI_XmlBlasterAccess.get(GetKey, GetQos)
public MsgUnit[] getCached(GetKey getKey,
GetQos getQos)
throws XmlBlasterException
I_XmlBlasterAccessA typical use case is a servlet which receives many HTML requests and usually the message has not changed. This way we avoid asking xmlBlaster every time for the information but take it directly from the cache.
The cache is always up to date as it has subscribed on this topic
You need to call createSynchronousCache() before using getCached().
NOTE: Passing two similar getKey but with different getQos filters is currently not supported.
NOTE: GetKey requests with EXACT oid are automatically removed from cache when the topic with this oid is erased. XPATH queries are removed from cache when the last topic oid which matched the XPATH disappears.
getCached in interface I_XmlBlasterAccessgetKey - Which message topics to retrievegetQos - Control the behavior and further filter messages with mime based filter plugins
XmlBlasterException - like ErrorCode.USER_NOT_CONNECTED and othersI_XmlBlasterAccess.getCached(GetKey, GetQos)
public MsgUnit[] get(GetKey getKey,
GetQos getQos)
throws XmlBlasterException
I_XmlBlasterAccess
get in interface I_XmlBlasterAccessgetKey - Which message topics to retrievegetQos - Control the behavior and further filter messages with mime based filter plugins
XmlBlasterException - like ErrorCode.USER_NOT_CONNECTED and othersI_XmlBlasterAccess.get(GetKey, GetQos)
public UnSubscribeReturnQos[] unSubscribe(UnSubscribeKey unSubscribeKey,
UnSubscribeQos unSubscribeQos)
throws XmlBlasterException
I_XmlBlasterAccess
unSubscribe in interface I_XmlBlasterAccessunSubscribeKey - Which messages to cancelunSubscribeQos - Control the behavior
XmlBlasterException - like ErrorCode.USER_NOT_CONNECTED and othersI_XmlBlasterAccess.unSubscribe(UnSubscribeKey, UnSubscribeQos)
public UnSubscribeReturnQos[] unSubscribe(java.lang.String xmlKey,
java.lang.String qos)
throws XmlBlasterException
unSubscribe in interface I_XmlBlasterXmlBlasterExceptionI_XmlBlasterAccess.unSubscribe(UnSubscribeKey, UnSubscribeQos)
public PublishReturnQos publish(MsgUnit msgUnit)
throws XmlBlasterException
publish in interface I_XmlBlasterAccessXmlBlasterExceptionI_XmlBlasterAccess.publish(MsgUnit)
public void publishOneway(MsgUnit[] msgUnitArr)
throws XmlBlasterException
I_XmlBlasterAccess
publishOneway in interface I_XmlBlasterAccessmsgUnitArr - The messages to send to the server
XmlBlasterException - like ErrorCode.USER_NOT_CONNECTED and othersI_XmlBlasterAccess.publishOneway(MsgUnit[])
public PublishReturnQos[] publishArr(MsgUnit[] msgUnitArr)
throws XmlBlasterException
publishArr in interface I_XmlBlasterXmlBlasterException
public EraseReturnQos[] erase(EraseKey eraseKey,
EraseQos eraseQos)
throws XmlBlasterException
erase in interface I_XmlBlasterAccesseraseKey - The topics to eraseeraseQos - Control the erase behavior
XmlBlasterException - like ErrorCode.USER_NOT_CONNECTED and othersI_XmlBlasterAccess.erase(EraseKey, EraseQos)
public EraseReturnQos[] erase(java.lang.String xmlKey,
java.lang.String qos)
throws XmlBlasterException
erase in interface I_XmlBlasterXmlBlasterExceptionI_XmlBlasterAccess.erase(EraseKey, EraseQos)
public java.lang.String update(java.lang.String cbSessionId,
UpdateKey updateKey,
byte[] content,
UpdateQos updateQos)
throws XmlBlasterException
update in interface I_Callbackupdate in class AbstractCallbackExtendedcbSessionId - The session ID specified by the client which registered the callbackupdateKey - The arrived key (as an xml-string)content - The arrived message contentupdateQos - Quality of Service of the MsgUnitRaw as an xml-string
XmlBlasterExceptionI_Callback.update(String, UpdateKey, byte[], UpdateQos)
public void toAlive(DispatchManager dispatchManager,
ConnectionStateEnum oldState)
toAlive in interface I_ConnectionStatusListener
public void toPolling(DispatchManager dispatchManager,
ConnectionStateEnum oldState)
toPolling in interface I_ConnectionStatusListener
public void toDead(DispatchManager dispatchManager,
ConnectionStateEnum oldState,
java.lang.String errorText)
Enforced by interface I_ConnectionStatusListener
toDead in interface I_ConnectionStatusListenerpublic Global getGlobal()
Enforced by interface I_XmlBlasterAccess
getGlobal in interface I_XmlBlasterAccesspublic I_Queue getQueue()
Enforced by interface I_ConnectionHandler
getQueue in interface