- public boolean equals(Object obj) {
- if (this == obj) {
- return true;
- }
- if (obj == null) {
- return false;
- }
- if (getClass() != obj.getClass()) {
- return false;
- }
- MockPayload other = (MockPayload) obj;
- if (value == null) {
- if (other.value != null) {
- return false;
- }
- } else if (!value.equals(other.value)) {
- return false;
- }
- return true;
- }
- }
-
- public static class MockReplicatedLogEntry implements ReplicatedLogEntry, Serializable {
- private static final long serialVersionUID = 1L;
-
- private final long term;
- private final long index;
- private final Payload data;
-
- public MockReplicatedLogEntry(long term, long index, Payload data){
-
- this.term = term;
- this.index = index;
- this.data = data;
- }
-
- @Override public Payload getData() {