|
||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object janus.net.Connection janus.net.LocalConnection
public class LocalConnection
Diese Klasse stellt die Verbindung der JAVA-Applikation über jToolkit zu den Servern auf einem HP NonStop-System her.
Field Summary | |
---|---|
protected com.tandem.tmf.ControlRef |
transactionHandle
TMF-Transaktions-Handle |
Constructor Summary | |
---|---|
LocalConnection(String init,
PrintWriter stream)
Konstruktor - Speichert die Parameter |
Method Summary | |
---|---|
ServerConnection |
acceptNew()
Umgekehrter Verbindungsaufbau für UMS Nicht implementiert! |
int |
awaitIo(int timeout)
Warte auf I/O. |
void |
cancel()
Breche Nowait-I/O ab. |
void |
connect()
Verbindungsaufbau mit den gespeicherten Parametern. |
void |
disconnect()
Verbindungsabbau |
void |
finalize()
Finalizer: Ruft disconnect() auf. |
static void |
main(String[] args)
Test |
protected com.tandem.tmf.Current |
resumeTransaction()
Nehme die aktuelle Transaktion wieder auf |
void |
sendBuffer(byte[] buffer,
int length)
Senden eines beliebigen Puffers. |
int |
sendMessage(String dest,
byte[] msg,
int msg_offset,
int msg_len,
byte[] reply,
int reply_offset,
int reply_len,
int timeout)
Message an Server mit Timeout. |
void |
sendTransaction(int type,
int success_lo,
int success_hi)
Transaktionsmessage. |
int |
sendUms(String terminal,
String alias,
byte[] msg,
int msg_offset,
int msg_len,
byte[] reply,
int reply_offset,
int reply_len)
Message an UMS-Client. |
protected void |
suspendTransaction(com.tandem.tmf.Current current)
Parke die aktuelle Transaktion. |
Methods inherited from class java.lang.Object |
---|
clone, equals, getClass, hashCode, notify, notifyAll, wait, wait, wait |
Field Detail |
---|
protected com.tandem.tmf.ControlRef transactionHandle
Constructor Detail |
---|
public LocalConnection(String init, PrintWriter stream) throws CommException
init
- Initialisierungs-Information (Pathmon oder RSC.INI-Datei)stream
- Ausgabe-Stream f¨r Debugging
CommException
- jToolkit nicht verfügbarMethod Detail |
---|
public ServerConnection acceptNew() throws CommException
acceptNew
in class Connection
CommException
- Allgemeiner Kommunikationsfehler
TandemException
- Tandem-Fehlerpublic int awaitIo(int timeout) throws CommException, TandemException
awaitIo
in class Connection
timeout
- Timeout (>=0 x0.01s)
CommException
- Allgemeiner Kommunikationsfehler
TandemException
- Tandem-Fehlerpublic void cancel() throws CommException, TandemException
cancel
in class Connection
CommException
- Allgemeiner Kommunikationsfehler
TandemException
- Tandem-Fehlerpublic void connect() throws CommException, TandemException
connect
in class Connection
CommException
- Allgemeiner Kommunikationsfehler
TandemException
- Tandem-Fehlerpublic void disconnect()
disconnect
in class Connection
public void finalize()
disconnect()
auf.
finalize
in class Connection
public static void main(String[] args) throws CommException
CommException
protected com.tandem.tmf.Current resumeTransaction() throws CommException
CommException
public void sendBuffer(byte[] buffer, int length) throws CommException
sendBuffer
in class Connection
buffer
- Datenlength
- Länge der Daten
CommException
- Allgemeiner Kommunikationsfehlerpublic int sendMessage(String dest, byte[] msg, int msg_offset, int msg_len, byte[] reply, int reply_offset, int reply_len, int timeout) throws CommException, TandemException
sendMessage
in class Connection
dest
- Name des Serversmsg
- Message (Eingabe)msg_offset
- Offset innerhalb von Messagemsg_len
- Länge der Messagereply
- Antwort (Ausgabe)reply_offset
- Offset innerhalb der Antwortreply_len
- Maximale Länge der Antworttimeout
- Timeout (-1 = ohne, 0 = Nowait, >0 = x0.01s)
CommException
- Allgemeiner Kommunikationsfehler
TandemException
- Tandem-Fehlerpublic void sendTransaction(int type, int success_lo, int success_hi) throws CommException, TandemException
sendTransaction
in class Connection
type
- Transaktionstyp (TT_BEGIN, TT_END, ...)success_lo
- Unterer Vergleichswert für AUTOCOMMIT (16 Bit)success_hi
- Oberer Vergleichswert für AUTOCOMMIT (16 Bit)
CommException
- Allgemeiner Kommunikationsfehler
TandemException
- Tandem-Fehlerpublic int sendUms(String terminal, String alias, byte[] msg, int msg_offset, int msg_len, byte[] reply, int reply_offset, int reply_len) throws CommException
sendUms
in class Connection
terminal
- UMS-Terminalnamealias
- UMS-Aliasnamemsg
- Message (Eingabe)msg_offset
- Offset innerhalb von Messagemsg_len
- Länge der Messagereply
- Antwort (Ausgabe)reply_offset
- Offset innerhalb der Antwortreply_len
- Maximale Länge der Antwort
CommException
- Allgemeiner Kommunikationsfehlerprotected void suspendTransaction(com.tandem.tmf.Current current) throws CommException
transactionHandle
und Connection.transaction
.
current
- Current-Objekt
CommException
|
||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |