Package com.google.code.yanf4j.core.impl

Examples of com.google.code.yanf4j.core.impl.ByteBufferCodecFactory$ByteBufferEncoder


    ByteBufferCodecFactory codecFactory;


    @Before
    public void setUp() {
        this.codecFactory = new ByteBufferCodecFactory();
    }
View Full Code Here


    }


    @Test
    public void testDirectEncoder() throws Exception {
        this.codecFactory = new ByteBufferCodecFactory(true);
        IoBuffer msg = IoBuffer.allocate(100);
        IoBuffer buffer = this.codecFactory.getEncoder().encode(msg, null);
        Assert.assertTrue(buffer.isDirect());
    }
View Full Code Here

    assertEquals("1.28", decodedCommand.getResult());
  }

  public MemcachedTCPSession buildSession() {
    NioSessionConfig sessionConfig = new NioSessionConfig(null,
        new HandlerAdapter(), null, new ByteBufferCodecFactory(), null,
        null, null, true, 0, 0);
    return new MemcachedTCPSession(sessionConfig, 16 * 1024, null, 0,
        new TextCommandFactory());
  }
View Full Code Here

TOP

Related Classes of com.google.code.yanf4j.core.impl.ByteBufferCodecFactory$ByteBufferEncoder

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.