WriteModification extends AbstractModification { public NormalizedNode<?, ?> getData() { return data; } WriteModification();  WriteModification(final short version);   WriteModification(final short version, final YangInstanceIdentifier path, final NormalizedNode<?, ?> data);  WriteModification(final YangInstanceIdentifier path, final NormalizedNode<?, ?> data); @Override void apply(final DOMStoreWriteTransaction transaction); @Override void apply(final DataTreeModification transaction); NormalizedNode<?, ?> getData(); @Override byte getType(); @Override void readExternal(final ObjectInput in); @Override void writeExternal(final ObjectOutput out); static WriteModification fromStream(final NormalizedNodeDataInput in, final short version,
            final ReusableStreamReceiver receiver); @Override void writeTo(final NormalizedNodeDataOutput out);  }
@Test public void testSerialization() { YangInstanceIdentifier path = TestModel.TEST_PATH; NormalizedNode<?, ?> data = ImmutableContainerNodeBuilder.create() .withNodeIdentifier(new YangInstanceIdentifier.NodeIdentifier(TestModel.TEST_QNAME)) .withChild(ImmutableNodes.leafNode(TestModel.DESC_QNAME, "foo")).build(); WriteModification expected = new WriteModification(path, data); WriteModification clone = (WriteModification) SerializationUtils.clone(expected); assertEquals("getPath", expected.getPath(), clone.getPath()); assertEquals("getData", expected.getData(), clone.getData()); }