Module com.hedera.hashgraph.sdk
Class EventDescriptor.Builder
java.lang.Object
com.google.protobuf.AbstractMessageLite.Builder<EventDescriptor,EventDescriptor.Builder>
com.google.protobuf.GeneratedMessageLite.Builder<EventDescriptor,EventDescriptor.Builder>
com.hedera.hapi.platform.event.legacy.EventDescriptor.Builder
- All Implemented Interfaces:
com.google.protobuf.MessageLite.Builder,com.google.protobuf.MessageLiteOrBuilder,EventDescriptorOrBuilder,Cloneable
- Enclosing class:
EventDescriptor
public static final class EventDescriptor.Builder
extends com.google.protobuf.GeneratedMessageLite.Builder<EventDescriptor,EventDescriptor.Builder>
implements EventDescriptorOrBuilder
* Unique identifier for an event.Protobuf type
com.hedera.hapi.platform.event.EventDescriptor-
Field Summary
Fields inherited from class com.google.protobuf.GeneratedMessageLite.Builder
instance -
Method Summary
Modifier and TypeMethodDescription* The birth round of the event.<br/> The birth round SHALL be the pending consensus round at the time the event is created.<br/> The pending consensus round SHALL be **one greater** than the latest round to reach consensus.* The creator node identifier.<br/> This SHALL be the unique identifier for the node that created the event.<br/> This SHALL match the ID of the node as it appears in the address book.* The generation of the event.<br/> This value SHALL be **one greater** than the _maximum_ generation of all parents.<br/>* The hash of the event.<br/> The hash SHALL be a SHA-384 hash.<br/> The hash SHALL have the following inputs, in the specified order:<br/> 1.long* The birth round of the event.<br/> The birth round SHALL be the pending consensus round at the time the event is created.<br/> The pending consensus round SHALL be **one greater** than the latest round to reach consensus.long* The creator node identifier.<br/> This SHALL be the unique identifier for the node that created the event.<br/> This SHALL match the ID of the node as it appears in the address book.long* The generation of the event.<br/> This value SHALL be **one greater** than the _maximum_ generation of all parents.<br/>com.google.protobuf.ByteStringgetHash()* The hash of the event.<br/> The hash SHALL be a SHA-384 hash.<br/> The hash SHALL have the following inputs, in the specified order:<br/> 1.setBirthRound(long value) * The birth round of the event.<br/> The birth round SHALL be the pending consensus round at the time the event is created.<br/> The pending consensus round SHALL be **one greater** than the latest round to reach consensus.setCreatorNodeId(long value) * The creator node identifier.<br/> This SHALL be the unique identifier for the node that created the event.<br/> This SHALL match the ID of the node as it appears in the address book.setGeneration(long value) * The generation of the event.<br/> This value SHALL be **one greater** than the _maximum_ generation of all parents.<br/>setHash(com.google.protobuf.ByteString value) * The hash of the event.<br/> The hash SHALL be a SHA-384 hash.<br/> The hash SHALL have the following inputs, in the specified order:<br/> 1.Methods inherited from class com.google.protobuf.GeneratedMessageLite.Builder
build, buildPartial, clear, clone, copyOnWrite, copyOnWriteInternal, getDefaultInstanceForType, internalMergeFrom, isInitialized, mergeFrom, mergeFrom, mergeFrom, mergeFromMethods inherited from class com.google.protobuf.AbstractMessageLite.Builder
addAll, addAll, mergeDelimitedFrom, mergeDelimitedFrom, mergeFrom, mergeFrom, mergeFrom, mergeFrom, mergeFrom, mergeFrom, mergeFrom, mergeFrom, newUninitializedMessageExceptionMethods inherited from class java.lang.Object
equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface com.google.protobuf.MessageLiteOrBuilder
getDefaultInstanceForType, isInitialized
-
Method Details
-
getHash
public com.google.protobuf.ByteString getHash()* The hash of the event.<br/> The hash SHALL be a SHA-384 hash.<br/> The hash SHALL have the following inputs, in the specified order:<br/> 1. The bytes of the `EventCore` protobuf<br/> 2. The SHA-384 hash of each individual `EventTransaction`, in the order the transactions appear in the `event_transactions` field of the `GossipEvent` protobuf
bytes hash = 1;- Specified by:
getHashin interfaceEventDescriptorOrBuilder- Returns:
- The hash.
-
setHash
* The hash of the event.<br/> The hash SHALL be a SHA-384 hash.<br/> The hash SHALL have the following inputs, in the specified order:<br/> 1. The bytes of the `EventCore` protobuf<br/> 2. The SHA-384 hash of each individual `EventTransaction`, in the order the transactions appear in the `event_transactions` field of the `GossipEvent` protobuf
bytes hash = 1;- Parameters:
value- The hash to set.- Returns:
- This builder for chaining.
-
clearHash
* The hash of the event.<br/> The hash SHALL be a SHA-384 hash.<br/> The hash SHALL have the following inputs, in the specified order:<br/> 1. The bytes of the `EventCore` protobuf<br/> 2. The SHA-384 hash of each individual `EventTransaction`, in the order the transactions appear in the `event_transactions` field of the `GossipEvent` protobuf
bytes hash = 1;- Returns:
- This builder for chaining.
-
getCreatorNodeId
public long getCreatorNodeId()* The creator node identifier.<br/> This SHALL be the unique identifier for the node that created the event.<br/> This SHALL match the ID of the node as it appears in the address book.
int64 creator_node_id = 2;- Specified by:
getCreatorNodeIdin interfaceEventDescriptorOrBuilder- Returns:
- The creatorNodeId.
-
setCreatorNodeId
* The creator node identifier.<br/> This SHALL be the unique identifier for the node that created the event.<br/> This SHALL match the ID of the node as it appears in the address book.
int64 creator_node_id = 2;- Parameters:
value- The creatorNodeId to set.- Returns:
- This builder for chaining.
-
clearCreatorNodeId
* The creator node identifier.<br/> This SHALL be the unique identifier for the node that created the event.<br/> This SHALL match the ID of the node as it appears in the address book.
int64 creator_node_id = 2;- Returns:
- This builder for chaining.
-
getBirthRound
public long getBirthRound()* The birth round of the event.<br/> The birth round SHALL be the pending consensus round at the time the event is created.<br/> The pending consensus round SHALL be **one greater** than the latest round to reach consensus.
int64 birth_round = 3;- Specified by:
getBirthRoundin interfaceEventDescriptorOrBuilder- Returns:
- The birthRound.
-
setBirthRound
* The birth round of the event.<br/> The birth round SHALL be the pending consensus round at the time the event is created.<br/> The pending consensus round SHALL be **one greater** than the latest round to reach consensus.
int64 birth_round = 3;- Parameters:
value- The birthRound to set.- Returns:
- This builder for chaining.
-
clearBirthRound
* The birth round of the event.<br/> The birth round SHALL be the pending consensus round at the time the event is created.<br/> The pending consensus round SHALL be **one greater** than the latest round to reach consensus.
int64 birth_round = 3;- Returns:
- This builder for chaining.
-
getGeneration
public long getGeneration()* The generation of the event.<br/> This value SHALL be **one greater** than the _maximum_ generation of all parents.<br/>
int64 generation = 17;- Specified by:
getGenerationin interfaceEventDescriptorOrBuilder- Returns:
- The generation.
-
setGeneration
* The generation of the event.<br/> This value SHALL be **one greater** than the _maximum_ generation of all parents.<br/>
int64 generation = 17;- Parameters:
value- The generation to set.- Returns:
- This builder for chaining.
-
clearGeneration
* The generation of the event.<br/> This value SHALL be **one greater** than the _maximum_ generation of all parents.<br/>
int64 generation = 17;- Returns:
- This builder for chaining.
-