OSCPort { public void connect() throws IOException { if (getRemoteAddress() == null) { throw new IllegalStateException( "Can not connect a socket without a remote address specified"); } getChannel().connect(getRemoteAddress()); } protected  OSCPort(final SocketAddress local, final SocketAddress remote); static int defaultSCOSCPort(); static int defaultSCLangOSCPort(); static InetAddress generateWildcard(final SocketAddress address); static int extractFamily(final SocketAddress address); void connect(); void disconnect(); boolean isConnected(); SocketAddress getLocalAddress(); SocketAddress getRemoteAddress(); void close(); static final int DEFAULT_SC_OSC_PORT; static final int DEFAULT_SC_LANG_OSC_PORT; }
@Test(expected=OSCSerializeException.class) public void testReceivingHugeConnectedOut() throws Exception { sender.connect(); testReceivingBySize(66000); }
@Test public void testBundleReceivingConnectedOut() throws Exception { sender.connect(); testBundleReceiving(true); }
@Test public void testBundleReceivingConnectedOutDifferentSender() throws Exception { reSetUpDifferentSender(); sender.connect(); testBundleReceiving(true); }
@Test public void testBundleReceivingConnectedOutDifferentReceiver() throws Exception { reSetUpDifferentReceiver(); sender.connect(); testBundleReceiving(false); }
@Test public void testBundleReceivingConnectedIn() throws Exception { reSetUpDifferentPorts(); receiver.connect(); testBundleReceiving(true); }
@Test public void testBundleReceivingConnectedInDifferentSender() throws Exception { reSetUpDifferentSender(); receiver.connect(); testBundleReceiving(false); }
@Test public void testBundleReceivingConnectedInDifferentReceiver() throws Exception { reSetUpDifferentReceiver(); receiver.connect(); testBundleReceiving(false); }
@Test public void testBundleReceivingConnectedBoth() throws Exception { reSetUpDifferentPorts(); receiver.connect(); sender.connect(); testBundleReceiving(true); }