@Test public void testClaStcpEid() { System.out.println("[+] eid: testing BaseClaEid Scheme"); try { BaseClaEid cla = new ClaStcpEid("google.com", 4556, "/"); assertEquals("cla:stcp:google.com:4556/", cla.getEidString()); assertEquals("stcp", cla.claName); assertEquals("google.com:4556", cla.claSpecific); assertEquals("/", cla.claSink); Eid eid = (new ClaStcpEidParser()).create("stcp","google.com:4556", ""); Eid path = (new ClaStcpEidParser()).create("stcp", "google.com:4556", "/pingservice"); assertEquals("cla:stcp:google.com:4556", eid.getEidString()); assertEquals("cla:stcp:google.com:4556/pingservice", path.getEidString()); assertTrue(path.matches(eid)); } catch (EidFormatException eid) { fail(eid.getMessage()); } }
private ClaStcpEid(String host, int port) { super("stcp", host + ":" + port); this.host = host; this.port = port; }
ClaStcpEid extends BaseClaEid { private ClaStcpEid(String host, int port) { super("stcp", host + ":" + port); this.host = host; this.port = port; } }
ClaStcpEid extends BaseClaEid { private ClaStcpEid(String host, int port) { super("stcp", host + ":" + port); this.host = host; this.port = port; } private  ClaStcpEid(String host, int port);  ClaStcpEid(String host, int port, String sink); }
ClaStcpEid extends BaseClaEid { private ClaStcpEid(String host, int port) { super("stcp", host + ":" + port); this.host = host; this.port = port; } private  ClaStcpEid(String host, int port);  ClaStcpEid(String host, int port, String sink); @Override int ianaNumber(); @Override Eid copy(); @Override boolean matches(Eid other); }
ClaStcpEid extends BaseClaEid { private ClaStcpEid(String host, int port) { super("stcp", host + ":" + port); this.host = host; this.port = port; } private  ClaStcpEid(String host, int port);  ClaStcpEid(String host, int port, String sink); @Override int ianaNumber(); @Override Eid copy(); @Override boolean matches(Eid other);  }