|
xmlBlaster 2.2.0 API | |||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectorg.xmlBlaster.client.protocol.corba.CorbaCallbackServer
public final class CorbaCallbackServer
Example for a CORBA callback implementation.
You can use this default callback handling with your clients, but if you need other handling of callbacks, take a copy of this Callback implementation and add your own code.
| Field Summary | |
|---|---|
private I_CallbackExtended |
boss
|
private BlasterCallback |
callback
|
private CallbackAddress |
callbackAddress
|
private Global |
glob
|
private static java.util.logging.Logger |
log
|
private java.lang.String |
ME
|
private org.omg.CORBA.ORB |
orb
|
private PluginInfo |
pluginInfo
|
private org.omg.PortableServer.POA |
rootPOA
|
| Constructor Summary | |
|---|---|
CorbaCallbackServer()
Called by plugin loader which calls init(Global, PluginInfo) thereafter. |
|
CorbaCallbackServer(Global glob,
java.lang.String name,
CallbackAddress callbackAddress,
I_CallbackExtended boss,
org.omg.CORBA.ORB orb_)
Construct a CORBA callback server for xmlBlaster, used by java/corba clients. |
|
| Method Summary | |
|---|---|
private void |
createCallbackServer()
Building a Callback server, using the tie approach. |
java.lang.String |
getCbAddress()
Returns the current callback address. |
java.lang.String |
getCbProtocol()
Returns the 'well known' protocol type. |
java.lang.String |
getType()
Enforced by I_Plugin |
java.lang.String |
getVersion()
Enforced by I_Plugin |
void |
init(Global glob,
PluginInfo pluginInfo)
This method is called by the PluginManager (enforced by I_Plugin). |
void |
initialize(Global glob,
java.lang.String name,
CallbackAddress callbackAddress,
I_CallbackExtended boss)
Construct a CORBA callback server for xmlBlaster, used by java/corba clients. |
java.lang.String |
ping(java.lang.String qos)
Ping to check if the callback server is alive. |
void |
shutdown()
Shutdown the callback server. |
java.lang.String[] |
update(java.lang.String cbSessionId,
MessageUnit[] msgUnitArr)
This is the callback method invoked from the CORBA server informing the client in an asynchronous mode about new messages. |
void |
updateOneway(java.lang.String cbSessionId,
MessageUnit[] msgUnitArr)
This is the callback method invoked from the CORBA server informing the client in an asynchronous mode about new messages. |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Field Detail |
|---|
private org.omg.CORBA.ORB orb
private org.omg.PortableServer.POA rootPOA
private BlasterCallback callback
private java.lang.String ME
private Global glob
private static java.util.logging.Logger log
private I_CallbackExtended boss
private CallbackAddress callbackAddress
private PluginInfo pluginInfo
| Constructor Detail |
|---|
public CorbaCallbackServer()
public CorbaCallbackServer(Global glob,
java.lang.String name,
CallbackAddress callbackAddress,
I_CallbackExtended boss,
org.omg.CORBA.ORB orb_)
throws XmlBlasterException
name - The login name of the client, for logging and identification with update() callbacks.boss - My client which wants to receive the update() calls.orb - A handle to my initialized orb
XmlBlasterException| Method Detail |
|---|
public void initialize(Global glob,
java.lang.String name,
CallbackAddress callbackAddress,
I_CallbackExtended boss)
throws XmlBlasterException
initialize in interface I_CallbackServername - The login name of the client, for logging onlyboss - My client which wants to receive the update() calls.glob - The global handle with your environment settingscallbackAddress - The address configuration of this callback server
XmlBlasterExceptionpublic java.lang.String getType()
getType in interface I_Pluginpublic java.lang.String getVersion()
getVersion in interface I_Plugin
public void init(Global glob,
PluginInfo pluginInfo)
init in interface I_PluginI_Plugin.init(org.xmlBlaster.util.Global,org.xmlBlaster.util.plugin.PluginInfo)
private void createCallbackServer()
throws XmlBlasterException
XmlBlasterException - if the BlasterCallback server can't be created
id="CallbackCreationError"public void shutdown()
shutdown in interface I_CallbackServershutdown in interface I_Pluginpublic final java.lang.String getCbProtocol()
I_CallbackServer
getCbProtocol in interface I_CallbackServer
public java.lang.String getCbAddress()
throws XmlBlasterException
I_CallbackServer
getCbAddress in interface I_CallbackServerXmlBlasterException
public void updateOneway(java.lang.String cbSessionId,
MessageUnit[] msgUnitArr)
updateOneway in interface BlasterCallbackOperationsmsgUnitArr - Contains a MsgUnitRaw structs (your message) for CORBA
public java.lang.String[] update(java.lang.String cbSessionId,
MessageUnit[] msgUnitArr)
throws XmlBlasterException
update in interface BlasterCallbackOperationsmsgUnitArr - Contains a MsgUnitRaw structs (your message) for CORBA
XmlBlasterExceptionpublic java.lang.String ping(java.lang.String qos)
ping in interface BlasterCallbackOperationsI_CallbackDriver.ping(String)
|
xmlBlaster 2.2.0 API | |||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||