class LocalReadWriteProxyTransaction extends LocalProxyTransaction {

    @Override
    Optional<ModifyTransactionRequest> flushState() {
        final ModifyTransactionRequestBuilder b = new ModifyTransactionRequestBuilder(getIdentifier(), localActor());
        b.setSequence(0);

        sealedModification.applyToCursor(new AbstractDataTreeModificationCursor() {
            @Override
            public void write(final PathArgument child, final NormalizedNode<?, ?> data) {
                b.addModification(new TransactionWrite(current().node(child), data));
            }

            @Override
            public void merge(final PathArgument child, final NormalizedNode<?, ?> data) {
                b.addModification(new TransactionMerge(current().node(child), data));
            }

            @Override
            public void delete(final PathArgument child) {
                b.addModification(new TransactionDelete(current().node(child)));
            }
        });

        return Optional.of(b.build());
    }

      LocalReadWriteProxyTransaction(final ProxyHistory parent, final TransactionIdentifier identifier,
        final DataTreeSnapshot snapshot);
      LocalReadWriteProxyTransaction(final ProxyHistory parent, final TransactionIdentifier identifier);

}