Package com.netflix.zeno.serializer

Examples of com.netflix.zeno.serializer.SerializerFactory


        System.out.println(Arrays.toString(reserializedStream.toByteArray()));

    }

    private FastBlobStateEngine typeAStateEngine() {
        return new FastBlobStateEngine(new SerializerFactory() {
            @Override
            public NFTypeSerializer<?>[] createSerializers() {
                // TODO Auto-generated method stub
                return new NFTypeSerializer<?>[] { new TypeASerializer() };
            }
View Full Code Here


        writer.writeSnapshot(baos);
        brokenDeltaChainSnapshot2 = baos.toByteArray();
   }

    private FastBlobStateEngine newStateEngine() {
        return new FastBlobStateEngine(new SerializerFactory() {
            public NFTypeSerializer<?>[] createSerializers() {
                return new NFTypeSerializer<?>[] { new TypeFSerializer() };
            }
        });
    }
View Full Code Here

        a2 = new TypeA(new TypeB(4, 5, 6), new TypeB(1, 92, 3), new TypeB(40, 41, 42));
    }

    @Test
    public void test() {
        SerializerFactory factory = new SerializerFactory() {
            public NFTypeSerializer<?>[] createSerializers() {
                return new NFTypeSerializer<?>[] { new ASerializer() };
            }
        };
View Full Code Here

    private FastBlobSerializationRecord rec;
    private FastBlobSchema schema;

    @Before
    public void setUp() {
        stateEngine = new FastBlobStateEngine(new SerializerFactory() {
            public NFTypeSerializer<?>[] createSerializers() {
                return new NFTypeSerializer<?>[] { new TestSchemaSerializer() };
            }
        });
View Full Code Here

    DiffSerializationFramework framework;

    @Before
    public void setUp() {
        framework = new DiffSerializationFramework(new SerializerFactory() {
            public NFTypeSerializer<?>[] createSerializers() {
                return new NFTypeSerializer<?>[] { new TypeASerializer() };
            }
        });
    }
View Full Code Here

        List<Field> objects1 = new ArrayList<Field>();
        List<Field> objects2 = new ArrayList<Field>();
        List<DiffRecord> recs1 = new ArrayList<DiffRecord>();
        List<DiffRecord> recs2 = new ArrayList<DiffRecord>();

        diffFramework = new DiffSerializationFramework(new SerializerFactory() {
            public NFTypeSerializer<?>[] createSerializers() {
                return new NFTypeSerializer<?>[] { new ASerializer() };
            }
        });
View Full Code Here

import com.netflix.zeno.testpojos.TypeASerializer;

public class DiffHistoryAbstractTest {

    protected SerializerFactory serializerFactory() {
        return new SerializerFactory() {
            public NFTypeSerializer<?>[] createSerializers() {
                return new NFTypeSerializer<?>[] { new TypeASerializer() };
            }
        };
    }
View Full Code Here

    private SerializerFactory typeASerializerFactory;
    private SerializerFactory typeGSerializerFactory;

    @Before
    public void setUp() {
        typeCSerializerFactory = new SerializerFactory() {
            public NFTypeSerializer<?>[] createSerializers() {
                return new NFTypeSerializer<?>[] { new TypeCSerializer() };
            }
        };

        typeASerializerFactory = new SerializerFactory() {
            public NFTypeSerializer<?>[] createSerializers() {
                return new NFTypeSerializer<?>[] { new TypeASerializer() };
            }
        };

        typeGSerializerFactory = new SerializerFactory() {
            public NFTypeSerializer<?>[] createSerializers() {
                return new NFTypeSerializer<?>[] { new TypeGSerializer() };
            }
        };
View Full Code Here

    public void roundTripJsonMap() throws IOException {
        Map<Integer, TypeA> map = new HashMap<Integer, TypeA>();
        map.put(1, new TypeA(0, 1));
        map.put(2, new TypeA(2, 3));

        JsonSerializationFramework jsonFramework = new JsonSerializationFramework(new SerializerFactory() {
            public NFTypeSerializer<?>[] createSerializers() {
                return new NFTypeSerializer<?>[] { new TypeASerializer(), new IntegerSerializer() };
            }
        });
View Full Code Here

    private TypeD d2;
    private TypeD d3;

    @Before
    public void setUp() throws Exception {
        typeDSerializerFactory = new SerializerFactory() {
            public NFTypeSerializer<?>[] createSerializers() {
                return new NFTypeSerializer<?>[] { new TypeDSerializer() };
            }
        };
View Full Code Here

TOP

Related Classes of com.netflix.zeno.serializer.SerializerFactory

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.