Examples of prepareForWrite()


Examples of com.netflix.zeno.fastblob.FastBlobStateEngine.prepareForWrite()

        FastBlobStateEngine stateEngine = typeAStateEngine();

        stateEngine.add("TypeA", new TypeA(1, 2));
        stateEngine.add("TypeA", new TypeA(3, 4));

        stateEngine.prepareForWrite();

        ByteArrayOutputStream baos = new ByteArrayOutputStream();

        FastBlobWriter writer = new FastBlobWriter(stateEngine);
        writer.writeSnapshot(baos);
View Full Code Here

Examples of com.netflix.zeno.fastblob.FastBlobStateEngine.prepareForWrite()

        reader.readSnapshot(new ByteArrayInputStream(baos.toByteArray()));

        deserializeEngine.fillSerializationStatesFromDeserializedData();

        deserializeEngine.prepareForWrite();

        ByteArrayOutputStream reserializedStream = new ByteArrayOutputStream();

        FastBlobWriter rewriter = new FastBlobWriter(deserializeEngine);
View Full Code Here

Examples of com.netflix.zeno.fastblob.FastBlobStateEngine.prepareForWrite()

        }

        ByteArrayOutputStream baos = new ByteArrayOutputStream();
        DataOutputStream dataOutputStream = new DataOutputStream(baos);

        stateEngine.prepareForWrite();

        FastBlobWriter writer = new FastBlobWriter(stateEngine);
        writer.writeSnapshot(dataOutputStream);

        FastBlobReader reader = new FastBlobReader(stateEngine);
View Full Code Here

Examples of com.netflix.zeno.fastblob.FastBlobStateEngine.prepareForWrite()

        stateEngine2.add("TypeB", new TypeB(3));

        stateEngine2.setLatestVersion("test");

        /// serialize a delta between the previous state and this state
        stateEngine2.prepareForWrite();

        ByteArrayOutputStream serializedDeltaState2 = new ByteArrayOutputStream();

        new FastBlobWriter(stateEngine2, 0).writeDelta(new DataOutputStream(serializedDeltaState2));
View Full Code Here

Examples of com.netflix.zeno.fastblob.FastBlobStateEngine.prepareForWrite()

        /// set the latest version
        stateEngine1.setLatestVersion("test1");

        /// serialize that data
        stateEngine1.prepareForWrite();

        ByteArrayOutputStream serializedSnapshotState1 = new ByteArrayOutputStream();

        new FastBlobWriter(stateEngine1, 0).writeSnapshot(new DataOutputStream(serializedSnapshotState1));
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. 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.