Package net.sf.cindy

Examples of net.sf.cindy.SessionHandlerAdapter


                return content.getString(Charset.SYSTEM, content.remaining());
            }
        });

        // set session handler
        session.setSessionHandler(new SessionHandlerAdapter() {

            public void objectReceived(Session session, Object obj)
                    throws Exception {
                System.out.println(obj);
            };
View Full Code Here


        // set packet encoder and decoder
        session.setPacketEncoder(new SerialEncoder());
        session.setPacketDecoder(new SerialDecoder());

        // set session handler
        session.setSessionHandler(new SessionHandlerAdapter() {

            public void sessionStarted(Session session) throws Exception {
                System.out.println("session started");
            }
View Full Code Here

            }
        }
    };

    public NonBlockingSessionAcceptor() {
        session.setSessionHandler(new SessionHandlerAdapter() {

            public void exceptionCaught(Session session, Throwable cause) {
                NonBlockingSessionAcceptor.this.exceptionCaught(cause);
            }
        });
View Full Code Here

TOP

Related Classes of net.sf.cindy.SessionHandlerAdapter

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.