Package org.activeio

Examples of org.activeio.AcceptListener


    public void doStart() throws Exception {
        final ReflexiveInterceptor loginServiceInterceptor = new ReflexiveInterceptor(loginService);

        server = createAsyncChannelServer();
        server.setAcceptListener(new AcceptListener() {
            public void onAccept(Channel channel) {
                RequestChannel requestChannel = null;
                try {
                    SyncChannel syncChannel = AsyncToSyncChannel.adapt(channel);
                    SocketMetadata socket = (SocketMetadata) syncChannel.narrow(SocketMetadata.class);
View Full Code Here


        SocketSyncChannelFactory factory = new SocketSyncChannelFactory();
        server = new SyncToAsyncChannelServer(
                factory.bindSyncChannel(new URI("tcp://localhost:0")));

        server.setAcceptListener(new AcceptListener() {
            public void onAccept(Channel channel) {
                RequestChannel requestChannel=null;
                try {

                    requestChannel =
View Full Code Here

        SynchChannelFactory factory = new SocketSynchChannelFactory();
       
        AsynchChannelServer server = new SynchToAsynchChannelServerAdapter(factory.bindSynchChannel(new URI("tcp://localhost:0")));
       
        server.setAcceptListener(new AcceptListener() {
            public void onAccept(Channel channel) {
             
                RequestChannel requestChannel = null;
                try {
                    ((SocketMetadata)channel.narrow(SocketMetadata.class)).setTcpNoDelay(true);
View Full Code Here

     * @throws IOException
     * @throws NamingException
     */
    protected void startIIOPServer() throws Exception {
        iiopServer = server.bindAsynchChannel(IIOPRecognizer.IIOP_RECOGNIZER);
        iiopServer.setAcceptListener(new AcceptListener() {
            public void onAccept(Channel channel) {
                try {
                    log.info("Got a IIOP connection.");
                    resultSlot.offer("IIOP", 1);
                    channel.dispose();
View Full Code Here

     * @throws IOException
     * @throws Exception
     */
    protected void startHTTPServer() throws Exception {
        httpServer = server.bindAsynchChannel(HttpRecognizer.HTTP_RECOGNIZER);
        httpServer.setAcceptListener(new AcceptListener() {
            public void onAccept(Channel channel) {
                try {
                    log.info("Got a HTTP connection.");
                    resultSlot.offer("HTTP", 1);

View Full Code Here

   
    public void doStart() throws Exception {
        final ReflexiveInterceptor loginServiceInterceptor = new ReflexiveInterceptor(loginService);
       
        server = createAsynchChannelServer();
        server.setAcceptListener(new AcceptListener() {
            public void onAccept(Channel channel) {
                RequestChannel requestChannel=null;
                try {
                    SynchChannel synchChannel = AsynchToSynchChannelAdapter.adapt(channel);
                    SocketMetadata socket = (SocketMetadata) synchChannel.narrow(SocketMetadata.class);
View Full Code Here

        SocketSynchChannelFactory factory = new SocketSynchChannelFactory();
        server = new SynchToAsynchChannelServerAdapter(
                factory.bindSynchChannel(new URI("tcp://localhost:0")));

        server.setAcceptListener(new AcceptListener() {
            public void onAccept(Channel channel) {
                RequestChannel requestChannel=null;
                try {

                    requestChannel =
View Full Code Here

TOP

Related Classes of org.activeio.AcceptListener

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.