All Downloads are FREE. Search and download functionalities are using the official Maven repository.

com.openelements.hiero.base.protocol.TopicCreateRequest Maven / Gradle / Ivy

The newest version!
package com.openelements.hiero.base.protocol;

import com.hedera.hashgraph.sdk.Hbar;
import java.time.Duration;
import org.jspecify.annotations.NonNull;

public record TopicCreateRequest(@NonNull Hbar maxTransactionFee,

                                 @NonNull Duration transactionValidDuration) implements TransactionRequest {

    public TopicCreateRequest {
        if (maxTransactionFee == null) {
            throw new NullPointerException("maxTransactionFee cannot be null");
        }
        if (transactionValidDuration == null) {
            throw new NullPointerException("transactionValidDuration cannot be null");
        }
    }

    public static TopicCreateRequest of() {
        return new TopicCreateRequest(TransactionRequest.DEFAULT_MAX_TRANSACTION_FEE,
                TransactionRequest.DEFAULT_TRANSACTION_VALID_DURATION);
    }


}




© 2015 - 2025 Weber Informatics LLC | Privacy Policy