Class RegisteredNodeCreateTransaction
This transaction, once complete, SHALL add a new registered node to the network state. The new registered node SHALL be visible and discoverable upon completion of this transaction.
-
Nested Class Summary
Nested classes/interfaces inherited from class com.hedera.hashgraph.sdk.Transaction
Transaction.SignableNodeTransactionBodyBytesNested classes/interfaces inherited from class com.hedera.hashgraph.sdk.Executable
Executable.GrpcRequest -
Field Summary
Fields inherited from class com.hedera.hashgraph.sdk.Transaction
customFeeLimits, DEFAULT_AUTO_RENEW_PERIOD, defaultMaxTransactionFee, DUMMY_ACCOUNT_ID, DUMMY_TRANSACTION_ID, frozenBodyBuilder, innerSignedTransactions, outerTransactions, publicKeys, regenerateTransactionId, signers, sigPairLists, sourceTransactionBody, transactionIdsFields inherited from class com.hedera.hashgraph.sdk.Executable
attemptedAllNodes, blockingUnaryCall, grpcDeadline, logger, maxAttempts, maxBackoff, minBackoff, nodeAccountIds, nodes, random, RST_STREAM -
Constructor Summary
ConstructorsConstructorDescriptionConstructor.Constructor.RegisteredNodeCreateTransaction(LinkedHashMap<TransactionId, LinkedHashMap<AccountId, Transaction>> txs) Constructor. -
Method Summary
Modifier and TypeMethodDescriptionaddServiceEndpoint(RegisteredServiceEndpoint serviceEndpoint) Add a service endpoint for the client calls.(package private) RegisteredNodeCreateTransactionBody.Builderbuild()Build the transaction body.Get administrative key controlled by the node operator.Get short description of the node.(package private) io.grpc.MethodDescriptor<Transaction, TransactionResponse> Called to direct the invocation of the query to the appropriate gRPC service.Get list of service endpoints for client calls.(package private) voidInitialize from the transaction body.(package private) voidonFreeze(TransactionBody.Builder bodyBuilder) Called inTransaction.freezeWith(Client)just before the transaction body is built.(package private) voidonScheduled(SchedulableTransactionBody.Builder scheduled) Called inTransaction.schedule()when converting transaction into a scheduled version.setAdminKey(Key adminKey) Set administrative key controlled by the node operator.setDescription(String description) A short description of the node.setServiceEndpoints(List<RegisteredServiceEndpoint> serviceEndpoints) A list of service endpoints for client calls.(package private) voidvalidateChecksums(Client client) Methods inherited from class com.hedera.hashgraph.sdk.Transaction
addSignature, addSignature, batchify, buildAllTransactions, buildTransaction, doSchedule, estimateFee, freeze, freezeWith, fromBytes, fromScheduledTransaction, generateTransactionIds, getBatchKey, getDefaultMaxTransactionFee, getExecutionState, getHighVolume, getMaxTransactionFee, getRegenerateTransactionId, getRequiredChunks, getSignableNodeBodyBytesList, getSignatures, getSignaturesAtOffset, getTransactionBodySize, getTransactionHash, getTransactionHashPerNode, getTransactionId, getTransactionIdInternal, getTransactionMemo, getTransactionSize, getTransactionValidDuration, hash, isBatchedAndNotBatchTransaction, isFrozen, keyAlreadySigned, makeRequest, mapResponse, mapResponseStatus, onExecute, onExecuteAsync, regenerateTransactionId, requireNotFrozen, requireOneNodeAccountId, schedule, setBatchKey, setHighVolume, setMaxTransactionFee, setNodeAccountIds, setRegenerateTransactionId, setTransactionId, setTransactionMemo, setTransactionValidDuration, sign, signTransaction, signWith, signWithOperator, spawnBodyBuilder, toBytes, toString, wipeTransactionListsMethods inherited from class com.hedera.hashgraph.sdk.Executable
advanceRequest, checkNodeAccountIds, execute, execute, executeAsync, executeAsync, executeAsync, executeAsync, executeAsync, executeAsync, getGrpcRequest, getMaxAttempts, getMaxBackoff, getMaxRetry, getMinBackoff, getNodeAccountIds, getNodeForExecute, grpcDeadline, logTransaction, mergeFromClient, setGrpcDeadline, setLogger, setMaxAttempts, setMaxBackoff, setMaxRetry, setMinBackoff, setNodesFromNodeAccountIds, setRequestListener, setResponseListener, shouldRetryExceptionally
-
Constructor Details
-
RegisteredNodeCreateTransaction
public RegisteredNodeCreateTransaction()Constructor. -
RegisteredNodeCreateTransaction
RegisteredNodeCreateTransaction(LinkedHashMap<TransactionId, LinkedHashMap<AccountId, throws com.google.protobuf.InvalidProtocolBufferExceptionTransaction>> txs) Constructor.- Parameters:
txs- Compound list of transaction id's list of (AccountId, Transaction) records- Throws:
com.google.protobuf.InvalidProtocolBufferException- when there is an issue with the protobuf
-
RegisteredNodeCreateTransaction
RegisteredNodeCreateTransaction(TransactionBody txBody) Constructor.- Parameters:
txBody- protobuf TransactionBody
-
-
Method Details
-
getAdminKey
Get administrative key controlled by the node operator.- Returns:
Keythe admin key
-
setAdminKey
Set administrative key controlled by the node operator.This key MUST sign this transaction.
This key MUST sign each transaction to update this node.
This field MUST contain a valid `Key` value.
This field is REQUIRED.- Parameters:
adminKey- the admin key for the registered node.- Returns:
this
-
getDescription
Get short description of the node.- Returns:
Stringthe node's description
-
setDescription
A short description of the node.This value, if set, MUST NOT exceed 100 bytes when encoded as UTF-8.
This field is OPTIONAL.- Parameters:
description- The string to be set as description for the node.- Returns:
this
-
getServiceEndpoints
Get list of service endpoints for client calls.- Returns:
List<RegisterServiceEndpoint>list of service endpoints
-
setServiceEndpoints
public RegisteredNodeCreateTransaction setServiceEndpoints(List<RegisteredServiceEndpoint> serviceEndpoints) A list of service endpoints for client calls.These endpoints SHALL represent the published endpoints to which clients may submit requests.
Endpoints in this list MAY supply either IP address or FQDN, but MUST NOT supply both values for the same endpoint.
Multiple endpoints in this list MAY resolve to the same interface.
One Registered Node MAY expose endpoints for multiple service types.
This list MUST NOT be empty.
This list MUST NOT contain more than `50` entries.- Parameters:
serviceEndpoints- the list of service endpoints for the client calls.- Returns:
this
-
addServiceEndpoint
public RegisteredNodeCreateTransaction addServiceEndpoint(RegisteredServiceEndpoint serviceEndpoint) Add a service endpoint for the client calls.- Parameters:
serviceEndpoint- the service endpoint- Returns:
this
-
build
Build the transaction body.- Returns:
RegisteredNodeCreateTransactionBody
-
initFromTransactionBody
void initFromTransactionBody()Initialize from the transaction body. -
validateChecksums
- Specified by:
validateChecksumsin classTransaction<RegisteredNodeCreateTransaction>- Throws:
BadEntityIdException
-
getMethodDescriptor
io.grpc.MethodDescriptor<Transaction,TransactionResponse> getMethodDescriptor()Description copied from class:ExecutableCalled to direct the invocation of the query to the appropriate gRPC service.- Specified by:
getMethodDescriptorin classExecutable<RegisteredNodeCreateTransaction,Transaction, TransactionResponse, TransactionResponse>
-
onFreeze
Description copied from class:TransactionCalled inTransaction.freezeWith(Client)just before the transaction body is built. The intent is for the derived class to assign their data variant to the transaction body.- Specified by:
onFreezein classTransaction<RegisteredNodeCreateTransaction>
-
onScheduled
Description copied from class:TransactionCalled inTransaction.schedule()when converting transaction into a scheduled version.- Specified by:
onScheduledin classTransaction<RegisteredNodeCreateTransaction>
-