|
ION Java User's Guide: ION Java Class and Method Reference |
|
If registered, the IONDisconnection() method is called when the connection between the client and the server is broken to report the reason for disconnection.
public abstract void IONDisconnection(int iStatus)
An integer corresponding to the reason for the disconnection. These are defined by the constants mentioned in the previous section.
None
import javax.swing.*;
import java.io.*;
import java.net.*;
import com.itt.ion.*;
public class disconnectEx extends JApplet
implements IONDisconnectListener {
IONGrConnection ionCon;
IONGrDrawable iondraw;
public void init() {
ionCon=new IONGrConnection();
ionCon.addIONDisconnectListener(this);
// connect to server and do ION commands
}
public void IONDisconnection(int iStatus) {
if (iStatus != IONDisconnectListener.ION_DIS_OK)
System.out.println("ION disconnection error.");
// do anything else to clean-up
}
}
IDL Online Help (March 06, 2007)