Home > Class Reference > ENSLIB namespace > EnsLib.JavaGateway.InboundAdapter

EnsLib.JavaGateway.InboundAdapter

class EnsLib.JavaGateway.InboundAdapter extends Ens.InboundAdapter, EnsLib.JavaGateway.Common

A generic inbound adapter class intended for use where a Java proxy class will be constructed and Ensemble will communicate with it by sending and retrieving message objects or data streams in a call-and-response fashion. This adapter can be used directly without subclassing if the Java proxy class implements the following methods: .Connect(pJGClientConnectSpec,pTimeout,pInbound) .Disconnect(pInbound) .IsConnected(pInbound) .getErrorText() [returns empty string if no error on previous method call] .ReceiveMessage(pTimeout) [inbound only; pMsgIn return needs not be populated if timed out] .SendResponse(pMsgOut) [inbound only, optional-needed if OnProcessInput will return an object] .SendMessage(pMsgOut,pGetReply,pResponseTimeout) [outbound only; pMsgIn return needs not be populated if no responses are anticipated] If a Java proxy cannot be constructed with this interface then you should subclass this adapter and the subclass can optionally override the following methods and call the Java proxy in whatever manner it must. .OnConnectProxy(pTimeout As %Numeric, pInbound As %Boolean) As %Status .OnDisconnectProxy(pInbound As %Boolean) As %Status .OnIsConnectedProxy(pInbound As %Boolean) As %Status .OnReceiveMessage(Output pMsgIn As %RegisteredObject) As %Status [inbound only] .OnSendResponse(pMsgOut As %RegisteredObject) As %Status [inbound only] .OnSendMessage(pMsgOut As %RegisteredObject, Output pMsgIn As %RegisteredObject) As %Status [outbound only]

Properties

property JGService as %String (MAXLEN = 128) [ Required ];
Config Name of the Java Gateway service controlling the Java Gateway server this Operation will use.
Property methods: JGServiceDisplayToLogical(), JGServiceGet(), JGServiceIsValid(), JGServiceLogicalToDisplay(), JGServiceLogicalToOdbc(), JGServiceNormalize(), JGServiceSet()

Methods

method OnInit() as %Status
Inherited description: This user callback method is called just after %OnNew()
method OnTask() as %Status
Inherited description: default InboundAdapter behavior: always call ProcessInput on CallInterval

Inherited Methods

%AddToSaveSet() %IsModified() Connect()
%ClassIsLatestVersion() %New() ConnectedSet()
%ClassName() %NormalizeObject() CredentialsSet()
%ConstructClone() %ObjectModified() Disconnect()
%DispatchClassMethod() %OriginalNamespace() EnumerateSettingsClose()
%DispatchGetModified() %PackageName() EnumerateSettingsExecute()
%DispatchGetProperty() %RemoveFromSaveSet() EnumerateSettingsFetch()
%DispatchMethod() %SerializeObject() GetSettings()
%DispatchSetModified() %SetModified() OnKeepalive()
%DispatchSetMultidimProperty() %ValidateObject() TestConnection()
%DispatchSetProperty() AssignOneSetting() initAdapterJG()
%Extends() ClearAllAppData() initJG()
%GetParameter() ClearRuntimeAppData()
%IsA() ClearStaticAppData()