Package com.bubble.serializer.objects

Examples of com.bubble.serializer.objects.PrivatePojo


 
  public void testPrivateSerializer() {
    Generator gen = new Generator();
    Serializer serializer = gen.getSerializer(PrivatePojo.class);
    assertNotNull("Serializer was null", serializer);
    PrivatePojo pojo = new PrivatePojo(TEST_VALUE);
    ByteBuffer buffer = ByteBuffer.allocate(1024);
    serializer.serializeInstanceInfo(pojo, buffer, null);
    serializer.serialize(pojo, buffer, null);
    buffer.flip();
    int val = buffer.getInt();
View Full Code Here


    buffer.flip();
    Object obj = deserializer.instantiate(buffer, null);
    assertNotNull("Instance was null", obj);
    assertTrue("Object was not a 'PrivatePojo'", obj instanceof PrivatePojo);
    deserializer.deserialize(obj, buffer, null);
    PrivatePojo pojo = (PrivatePojo)obj;
    assertEquals("Value field with wrong value", TEST_VALUE, pojo.getValue());
  }
View Full Code Here

TOP

Related Classes of com.bubble.serializer.objects.PrivatePojo

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.