import org.opendaylight.controller.cluster.datastore.persisted.DataTreeCandidateInputOutput;
import org.opendaylight.controller.cluster.raft.protobuff.client.messages.Payload;
import org.opendaylight.yangtools.yang.data.api.schema.tree.DataTreeCandidate;
-import org.slf4j.Logger;
-import org.slf4j.LoggerFactory;
+/**
+ * @deprecated Deprecated in Boron in favor of CommitTransactionPayload
+ */
+@Deprecated
final class DataTreeCandidatePayload extends Payload implements Externalizable {
- private static final Logger LOG = LoggerFactory.getLogger(DataTreeCandidatePayload.class);
private static final long serialVersionUID = 1L;
private transient byte[] serialized;
this.serialized = Preconditions.checkNotNull(serialized);
}
+ /**
+ * @deprecated Use CommitTransactionPayload instead
+ */
+ @Deprecated
static DataTreeCandidatePayload create(final DataTreeCandidate candidate) {
final ByteArrayDataOutput out = ByteStreams.newDataOutput();
try {
return new DataTreeCandidatePayload(out.toByteArray());
}
-
- DataTreeCandidate getCandidate() throws IOException {
+ public DataTreeCandidate getCandidate() throws IOException {
return DataTreeCandidateInputOutput.readDataTreeCandidate(ByteStreams.newDataInput(serialized));
}