package fr.dgac.ivy ;
import java.awt.BorderLayout;
import java.awt.event.*;
import javax.swing.* ;
import gnu.getopt.Getopt ;
/**
* toy tool to probe the Ivy software bus.
* it relies on the Swing toolkit, which is not standard on jdk1.1 platform.
* if you don't have jdk1.2 or swing, consider downloading it. You can also
* use TestIvy
*
* @see fr.dgac.ivy.TestIvy
* @author François-Régis Colin
* @author Yannick Jestin
* @author http://www.tls.cena.fr/products/ivy/
*/
class TestIvySwing extends JPanel implements IvyApplicationListener {
/**
* help message for the standalone program
*/
public static final String helpmsg = "usage: java fr.dgac.ivy.TestIvySwing [options]\n\t-b BUS\tspecifies the Ivy bus domain\n\t-q\tquiet, no tty output\n\t-d\tdebug\n\t-h\thelp\n";
public static final int WIDTH=30;
public static final int HEIGHT=30;
private static int index;
private static int nbTIS=0;
private String localname;
private Ivy bus ;
private String domain;
private String regexp = "(.*)";
private JLabel laRegex;
private JTextArea ta ;
private JTextField tfRegex, tfSend ;
private JButton buApply, buSend, buClear ;
private JComboBox ports;
private int regexp_id;
private REGCB reg;
private java.text.SimpleDateFormat format = new java.text.SimpleDateFormat("hh:mm:ss");
private static String[] startDomainList = {
"127.255.255.255:2010",
"10.192.36:3110",
"10.0.0:54321",
"228.1.2.4:4567",
};
private static java.util.Vector domainList;
static {
// initialize the domainlist
domainList = new java.util.Vector();
for (int i = 0; i