public final class SimpleReplicatedLogEntry extends Object implements ReplicatedLogEntry, Serializable
ReplicatedLogEntry
implementation.Constructor and Description |
---|
SimpleReplicatedLogEntry(long index,
long term,
Payload payload)
Constructs an instance.
|
Modifier and Type | Method and Description |
---|---|
boolean |
equals(Object obj) |
int |
estimatedSerializedSize() |
Payload |
getData()
Returns the payload/data to be replicated.
|
long |
getIndex()
Returns the index of the entry.
|
long |
getTerm()
Returns the term of the entry.
|
int |
hashCode() |
boolean |
isPersistencePending()
Checks if persistence is pending for this entry.
|
void |
setPersistencePending(boolean pending)
Sets whether or not persistence is pending for this entry.
|
int |
size()
Returns the size of the entry in bytes.
|
String |
toString() |
public SimpleReplicatedLogEntry(long index, long term, Payload payload)
index
- the indexterm
- the termpayload
- the payloadpublic Payload getData()
ReplicatedLogEntry
getData
in interface ReplicatedLogEntry
public long getTerm()
ReplicatedLogEntry
getTerm
in interface ReplicatedLogEntry
public long getIndex()
ReplicatedLogEntry
getIndex
in interface ReplicatedLogEntry
public int size()
ReplicatedLogEntry
size
in interface ReplicatedLogEntry
public boolean isPersistencePending()
ReplicatedLogEntry
isPersistencePending
in interface ReplicatedLogEntry
public void setPersistencePending(boolean pending)
ReplicatedLogEntry
setPersistencePending
in interface ReplicatedLogEntry
pending
- the new setting.public int estimatedSerializedSize()
Copyright © 2019 OpenDaylight. All rights reserved.