|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||
java.lang.Objectse.entra.phantom.server.ClientSession
public class ClientSession
The threaded client session that one clients can connect to.
| Method Summary | |
|---|---|
void |
checkInactivity(int inactivityWarning,
int inactivityTimeout)
Checks if a warning message should be displayed on the client due to inactivity or if the session should be closed. |
void |
clientTrace(String text)
Performs a trace output (normally after a call to doClientVerboseTrace. |
Transaction |
createTransaction()
Create Transaction depending on the current codepage for this session. |
void |
displayTerminal()
Creates the terminal window, gets the contents of the terminal window, hides all the panels, and displays it. |
void |
displayTerminal(boolean keepVisible)
Creates the terminal window, gets the contents of the terminal window, hides all the panels, and displays it. |
void |
displayTerminal(boolean keepVisible,
String heading)
Creates the terminal window, gets the contents of the terminal window, hides all the panels, and displays it. |
void |
dispose()
Disposes of the client session. |
boolean |
doClientVerboseTrace()
Checks if client verbose trace is turned on. |
boolean |
doesScreenContainData()
Checks if the host screen contains data. |
boolean |
doesScreenMatch(PhantomHostScreen phantomScreen)
Checks if a host screen currently matches. |
void |
dontUpdateLastTime()
Causes the last client transaction time not to be set after processing of a client event. |
void |
enableWriteCache(IniFile ini)
Enables the write cache of string for the Java Client. |
boolean |
exitApplication()
Exits the current client session. |
void |
flagClientEventForProcessing()
Flags a client event to be processed asynchronously. |
void |
flagHostEventForProcessing()
Flags a host event to be processed asynchronously. |
ClientCommunicationInterface |
getClientCommunicationInterface()
Gets the client communication interface.. |
ClientCommunicationListener |
getClientCommunicationListener()
Gets the non-Java client listener. |
ClientConnectionData |
getClientConnectionData()
Gets the client connection data. |
se.entra.phantom.server.ClientJar |
getClientJar(String fn)
Gets a Client JAR from a file request. |
ClientSessionManager |
getClientSessionManager()
Gets a instance of the Client Session Manager. |
ClientWorker |
getClientWorker()
Get client worker. |
Object |
getComponentLockObject()
Gets the lock object for synchronization for Control Components. |
long |
getConnectionID()
Gets the client connection ID. |
HostSession |
getCurrentHostSession()
Gets the current host session. |
HostScreen |
getHostScreen()
Gets the host screen. |
HostSessionManager |
getHostSessionManager()
Gets the host session manager. |
long |
getLastTransactionTime()
The last transaction time in "System.currentTimeMillis()". |
Object |
getLockObject()
Gets the lock object (the virtual session manager). |
Transaction |
getModalReturnCode(int replyType)
Gets the return code (Transaction) for a modal server-client request. |
PhantomRuntime |
getRuntimeApplication(String name)
Gets a runtime application of an ID. |
int |
getSessionType()
Gets the session type. |
long |
getWarningTime()
Gets the warning time in milliseconds. |
VirtualSessionManager |
getVirtualSessionManager()
Gets the VirtualSessionManager. |
boolean |
grabSessionFromPool(String[] runtimeIDs,
int hostID)
Checks if there is a session pooling handler that can be used for this client session. |
boolean |
hasJavaClient()
Checks if this session is connected to a NetPhantom Java Client. |
boolean |
hasSessionTimedOut(long timeoutMillis)
Checks if a session has been inactive for a certain amount of time. |
boolean |
initialize()
Initiates a new session that is not connected to the NetPhantom Java Client. |
boolean |
initialize(boolean isEditor)
Initiates a new session and indicates if it should be run in editor mode. |
Object |
invokeAndWait(ServerAction serverAction)
Invokes the server action in the client worker thread and waits for a reply. |
void |
invokeLater(ServerAction serverAction)
Invokes the server action in the client worker thread later and doesn't wait for a reply. |
boolean |
isClientTerminalDisplayed()
Checks if the client is displaying the terminal window. |
boolean |
isClientTerminalDisplayedProgrammatically()
Checks if the client is displaying the terminal window programmatically. |
boolean |
isDisposed()
Checks if the session is disposed. |
boolean |
isEditor()
Is this an editor instance. |
boolean |
isEditorParallelRun()
Checks the flag to indicate that the instance runs in parallel with the editor. |
boolean |
isHostInducedHostChange()
Checks if a host change (typically in a VirtualControl.refresh) is induced from host or from local host interaction. |
boolean |
isHostInErrorState()
Checks if the current host session is in error state. |
boolean |
isHostLocked()
Checks if the current host session is locked. |
boolean |
isInitialized()
Is this initialized. |
boolean |
isMainThread()
Checks if the current calling thread is the main thread. |
boolean |
isServerAdministration()
Checks if the server administration is the current application. |
void |
logEvent(int id)
Logs an event for the client. |
void |
logEvent(int id,
String param)
Logs an event for the client. |
void |
onHostConnectChange(boolean connected)
Notifies the session of a connect state change. |
void |
onHostCursorPositionChange(int x,
int y)
Informs that the cursor position has changed. |
void |
onHostDataStreamProcessing(boolean isEntering)
Called when entering or exiting data stream processing. |
void |
onHostFieldChange()
Notifies the session that fields have changed. |
void |
onHostPrinterSessionFailure(Throwable exception)
Called when a printer session has had a failure. |
void |
onHostScreenChange()
Notifies the session of a screen change. |
void |
onHostSessionChange(HostSession hostSession,
boolean isNewSession)
Called when the current host session is changed. |
void |
onHostSessionFailure(String description)
Deprecated. as of NetPhantom Version 3.8 |
void |
onHostSessionFailure(Throwable exception)
Called when a session has had a failure. |
void |
onHostStateChange()
Notifies the session of a state change (such as insert mode, lock state, error state). |
void |
postClientTransaction(Transaction trans)
Posts a client transaction for processing. |
boolean |
postMessageBoxTransaction(VirtualMessageBox vmb)
Post a transaction to sent to the client from queue. |
void |
processCheckInactivity(int inactivityWarning,
int inactivityTimeout)
Checks if a warning message should be displayed on the client due to inactivity or if the session should be closed. |
void |
processClientEvent()
Process a new client event. |
void |
processClientTransaction(Transaction trans)
Processes events posted to the client worker for processing in the virtual session manager. |
void |
processHostEvent()
Process a new host event. |
void |
removeTerminal()
Removes the terminal window and displays all the panels again. |
void |
removeTerminal(boolean alwaysRemove)
Removes the terminal window and displays all the panels again. |
void |
run()
Starts running the threaded Client Session. |
void |
sendNegotiateSSL()
Sends the negotiate SSL transaction to the client and waits for the reader thread to reply (it gets held for a while). |
void |
sendTransaction(Transaction trans)
Sends a transaction to the client. |
void |
sendTransaction(Transaction trans,
boolean doSetLastTransactionTime)
Sends a transaction to the client. |
void |
setHostSessionManager(HostSessionManager manager)
Sets the host session manager. |
void |
setInitialized(boolean init)
Set initialized. |
void |
setLastTransactionTime()
Sets the last timestamp for a transaction between the client and the server. |
void |
setModalReturnCode(Transaction trans)
Sets the return code for a server-client request (message box). |
void |
setVirtualSessionManager(VirtualSessionManager manager)
Sets the VirtualSessionManager. |
void |
soundAlarm()
Sound alarm on the client. |
void |
soundAlarm(boolean fromHost)
Sound alarm on the client. |
boolean |
waitForScreenChange(long msTime)
Waits for a screen change for a certain time. |
boolean |
waitForUnlock(long msTime)
Waits for the lock state to disappear for a certain time. |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Method Detail |
|---|
public int getSessionType()
public boolean initialize()
public boolean initialize(boolean isEditor)
public Object getLockObject()
getLockObject in interface HostSessionManagerListenerpublic boolean isDisposed()
public void dispose()
dispose in interface ClientSessionInterfacepublic void sendNegotiateSSL()
public boolean isEditor()
public boolean isInitialized()
public void setInitialized(boolean init)
boolean - public boolean isEditorParallelRun()
public boolean isServerAdministration()
public void run()
run in interface Runnablepublic ClientCommunicationInterface getClientCommunicationInterface()
getClientCommunicationInterface in interface ClientSessionInterfacepublic long getConnectionID()
public boolean doesScreenMatch(PhantomHostScreen phantomScreen)
doesScreenMatch in interface HostSessionManagerListenerpublic VirtualSessionManager getVirtualSessionManager()
getVirtualSessionManager in interface ClientSessionInterfacepublic void setVirtualSessionManager(VirtualSessionManager manager)
public PhantomRuntime getRuntimeApplication(String name)
public ClientSessionManager getClientSessionManager()
public final ClientConnectionData getClientConnectionData()
getClientConnectionData in interface ClientSessionInterfacepublic void enableWriteCache(IniFile ini)
public void sendTransaction(Transaction trans)
sendTransaction in interface ClientSessionInterface
public void sendTransaction(Transaction trans,
boolean doSetLastTransactionTime)
public void flagClientEventForProcessing()
flagClientEventForProcessing in interface ClientSessionInterfacepublic void flagHostEventForProcessing()
flagHostEventForProcessing in interface ClientSessionInterfacepublic void postClientTransaction(Transaction trans)
postClientTransaction in interface ClientSessionInterfacepublic boolean postMessageBoxTransaction(VirtualMessageBox vmb)
public void setModalReturnCode(Transaction trans)
setModalReturnCode in interface ClientSessionInterfacepublic Transaction getModalReturnCode(int replyType)
getModalReturnCode in interface ClientSessionInterfacepublic HostScreen getHostScreen()
getHostScreen in interface ClientSessionInterfacepublic HostSessionManager getHostSessionManager()
getHostSessionManager in interface ClientSessionInterfacepublic void setHostSessionManager(HostSessionManager manager)
public HostSession getCurrentHostSession()
getCurrentHostSession in interface ClientSessionInterfacepublic boolean isHostLocked()
isHostLocked in interface ClientSessionInterfacepublic boolean isHostInErrorState()
isHostInErrorState in interface ClientSessionInterfacepublic boolean isHostInducedHostChange()
public boolean waitForUnlock(long msTime)
waitForUnlock in interface ClientSessionInterfacepublic boolean waitForScreenChange(long msTime)
waitForScreenChange in interface ClientSessionInterfacepublic Object getComponentLockObject()
public void onHostConnectChange(boolean connected)
onHostConnectChange in interface HostSessionManagerListenerpublic boolean doesScreenContainData()
doesScreenContainData in interface ClientSessionInterfacepublic void onHostStateChange()
onHostStateChange in interface HostSessionManagerListenerpublic void onHostFieldChange()
onHostFieldChange in interface HostSessionManagerListenerpublic void onHostScreenChange()
onHostScreenChange in interface HostSessionManagerListener
public void onHostCursorPositionChange(int x,
int y)
onHostCursorPositionChange in interface HostSessionManagerListenerpublic void processHostEvent()
processHostEvent in interface ClientSessionInterfacepublic void processClientEvent()
processClientEvent in interface ClientSessionInterfacepublic void processClientTransaction(Transaction trans)
processClientTransaction in interface ClientSessionInterfacepublic boolean isMainThread()
isMainThread in interface ClientSessionInterfacepublic boolean exitApplication()
The connection to the client will be closed and the terminal sessions stopped. The session will then be restarted for use by another client session.
exitApplication in interface ClientSessionInterfacepublic void displayTerminal()
displayTerminal in interface ClientSessionInterfacepublic void displayTerminal(boolean keepVisible)
public void displayTerminal(boolean keepVisible,
String heading)
public void removeTerminal()
removeTerminal in interface ClientSessionInterfacepublic void removeTerminal(boolean alwaysRemove)
public boolean isClientTerminalDisplayed()
isClientTerminalDisplayed in interface ClientSessionInterfacepublic boolean isClientTerminalDisplayedProgrammatically()
public void soundAlarm()
soundAlarm in interface ClientSessionInterfacesoundAlarm in interface HostSessionManagerListenerpublic void soundAlarm(boolean fromHost)
public ClientWorker getClientWorker()
getClientWorker in interface ClientSessionInterface@Deprecated public void onHostSessionFailure(String description)
onHostSessionFailure in interface HostSessionManagerListenerpublic void onHostSessionFailure(Throwable exception)
onHostSessionFailure in interface HostSessionManagerListener2public void onHostPrinterSessionFailure(Throwable exception)
public void logEvent(int id)
logEvent in interface ClientSessionInterface
public void logEvent(int id,
String param)
logEvent in interface ClientSessionInterfacepublic long getWarningTime()
public void setLastTransactionTime()
public long getLastTransactionTime()
public void dontUpdateLastTime()
public void checkInactivity(int inactivityWarning,
int inactivityTimeout)
public void processCheckInactivity(int inactivityWarning,
int inactivityTimeout)
processCheckInactivity in interface ClientSessionInterfacepublic boolean hasSessionTimedOut(long timeoutMillis)
public boolean doClientVerboseTrace()
doClientVerboseTrace in interface ClientSessionInterfacepublic void clientTrace(String text)
doClientVerboseTrace.
clientTrace in interface ClientSessionInterfacepublic Transaction createTransaction()
createTransaction in interface ClientSessionInterfacepublic boolean hasJavaClient()
hasJavaClient in interface ClientSessionInterfacepublic ClientCommunicationListener getClientCommunicationListener()
public boolean grabSessionFromPool(String[] runtimeIDs,
int hostID)
This function will change the hostSessionManager in the case
of a successful grab or a session in the session pool.
public void onHostSessionChange(HostSession hostSession,
boolean isNewSession)
onHostSessionChange in interface HostSessionManagerListenerpublic void onHostDataStreamProcessing(boolean isEntering)
onHostDataStreamProcessing in interface HostSessionManagerListenerpublic void invokeLater(ServerAction serverAction)
public Object invokeAndWait(ServerAction serverAction)
public se.entra.phantom.server.ClientJar getClientJar(String fn)
|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||