Mercurial > hg > FederatedLinda
view src/fdl/TestEtc.java @ 3:ae7e0e92c651
*** empty log message ***
author | fuchita |
---|---|
date | Mon, 11 Feb 2008 11:54:15 +0900 |
parents | 083a0b5e12cc |
children | 2023d9b31af9 |
line wrap: on
line source
package fdl; import java.io.IOException; import java.nio.ByteBuffer; public class TestEtc implements PSXQueueInterface { static final int MAX_REQ = 1; static final int FAIL = (-1); static final int MAX_UAER = 4; static final int MAX_TUPLE = 65536; static final int MAX_BUFFSIZE = 2048; static final int DEF_PORT = 10000; static final String PATHNAME = "/tmp/ldserv"; static final int LINDA_MODE_OFFSET = 0; static final int LINDA_ID_OFFSET = 1; static final int LINDA_SEQ_OFFSET = 3; static final int LINDA_DATA_LENGTH_OFFSET = 7; static final int LINDA_HEADER_SIZE = 12; static final boolean debug = true; public PSXQueue tuple_space; public PSXQueue tp; public static void main(String[] args) throws IOException { String socketString = "java.nio.channels.SocketChannel[connected local=/133.13.57.210:10001 remote=/133.13.57.210:50634]"; String[] split = socketString.split("/"); String local[] = split[1].split(" "); String remote[] = split[2].split("]"); String localAddress = local[0]; String remoteAddress = remote[0]; System.out.println(local[0]); System.out.println(remote[0]); // System.out.println("tmpTuple "+tmpTuple.toString()); // System.out.println("testTS "+testTS[MAX_TUPLE-1].toString()); } }