Package com.dyuproject.protostuff.runtime

Examples of com.dyuproject.protostuff.runtime.Foo


   
    public void testFoo() throws Exception
    {
        Schema<Foo> schema = RuntimeSchema.getSchema(Foo.class);
       
        Foo fooCompare = foo;
        Foo dfoo = new Foo();
       
        byte[] data = JsonIOUtil.toByteArray(fooCompare, schema, true);
        JsonIOUtil.mergeFrom(data, dfoo, schema, true);
        SerializableObjects.assertEquals(fooCompare, dfoo);
    }
View Full Code Here


   
    public void testFoo() throws Exception
    {
        Schema<Foo> schema = RuntimeSchema.getSchema(Foo.class);
       
        Foo fooCompare = foo;
        Foo dfoo = new Foo();
       
        byte[] data = JsonXIOUtil.toByteArray(fooCompare, schema, true, buf());
        JsonIOUtil.mergeFrom(data, dfoo, schema, true);
        SerializableObjects.assertEquals(fooCompare, dfoo);
    }
View Full Code Here

   
    public void testFooStreamed() throws Exception
    {
        Schema<Foo> schema = RuntimeSchema.getSchema(Foo.class);
       
        Foo fooCompare = foo;
        Foo dfoo = new Foo();

        ByteArrayOutputStream out = new ByteArrayOutputStream();
        LinkedBuffer buffer = buf();
        try
        {
View Full Code Here

   
    public void testFoo() throws Exception
    {
        Schema<Foo> schema = RuntimeSchema.getSchema(Foo.class);
       
        Foo fooCompare = foo;
        Foo dfoo = new Foo();
       
        byte[] data = JsonIOUtil.toByteArray(fooCompare, schema, false);
        JsonIOUtil.mergeFrom(data, dfoo, schema, false);
        SerializableObjects.assertEquals(fooCompare, dfoo);
    }
View Full Code Here

   
    public void testFoo() throws Exception
    {
        Schema<Foo> schema = RuntimeSchema.getSchema(Foo.class);
       
        Foo fooCompare = foo;
        Foo dfoo = new Foo();
       
        byte[] data = XmlIOUtil.toByteArray(fooCompare, schema);
        XmlIOUtil.mergeFrom(data, dfoo, schema);
        SerializableObjects.assertEquals(fooCompare, dfoo);
    }
View Full Code Here

    public void testFoo() throws Exception
    {
        Schema<Foo> schema = RuntimeSchema.getSchema(Foo.class);
        Pipe.Schema<Foo> pipeSchema = ((MappedSchema<Foo>)schema).getPipeSchema();
       
        Foo foo = SerializableObjects.foo;
       
       
        protobufRoundTrip(foo, schema, pipeSchema, false);
        protostuffRoundTrip(foo, schema, pipeSchema, false);
       
View Full Code Here

TOP

Related Classes of com.dyuproject.protostuff.runtime.Foo

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.