java.lang.Object
com.google.protobuf.AbstractMessageLite<NftAllowance,NftAllowance.Builder>
com.google.protobuf.GeneratedMessageLite<NftAllowance,NftAllowance.Builder>
com.hedera.hashgraph.sdk.proto.NftAllowance
- All Implemented Interfaces:
com.google.protobuf.MessageLite,com.google.protobuf.MessageLiteOrBuilder,NftAllowanceOrBuilder
@Generated
public final class NftAllowance
extends com.google.protobuf.GeneratedMessageLite<NftAllowance,NftAllowance.Builder>
implements NftAllowanceOrBuilder
* An approved allowance of non-fungible tokens.<br/> This type of allowance may permit transfers for one or more individual unique tokens, or may permit transfers for all unique tokens of the specified type. If `owner` is not set, the effective `owner` SHALL be the `payer` for the enclosing transaction.<br/> The `spender` MUST be specified and MUST be a valid account.<br/> If `approve_for_all` is set, then `serial_numbers` SHOULD be empty and SHALL be ignored. If `approve_for_all` is unset, then `serial_numbers` MUST NOT be empty.Protobuf type
proto.NftAllowance-
Nested Class Summary
Nested ClassesModifier and TypeClassDescriptionstatic final class* An approved allowance of non-fungible tokens.<br/> This type of allowance may permit transfers for one or more individual unique tokens, or may permit transfers for all unique tokens of the specified type.Nested classes/interfaces inherited from class com.google.protobuf.GeneratedMessageLite
com.google.protobuf.GeneratedMessageLite.DefaultInstanceBasedParser<T extends com.google.protobuf.GeneratedMessageLite<T,?>>, com.google.protobuf.GeneratedMessageLite.ExtendableBuilder<MessageType extends com.google.protobuf.GeneratedMessageLite.ExtendableMessage<MessageType, BuilderType>, BuilderType extends com.google.protobuf.GeneratedMessageLite.ExtendableBuilder<MessageType, BuilderType>>, com.google.protobuf.GeneratedMessageLite.ExtendableMessage<MessageType extends com.google.protobuf.GeneratedMessageLite.ExtendableMessage<MessageType, BuilderType>, BuilderType extends com.google.protobuf.GeneratedMessageLite.ExtendableBuilder<MessageType, BuilderType>>, com.google.protobuf.GeneratedMessageLite.ExtendableMessageOrBuilder<MessageType extends com.google.protobuf.GeneratedMessageLite.ExtendableMessage<MessageType, BuilderType>, BuilderType extends com.google.protobuf.GeneratedMessageLite.ExtendableBuilder<MessageType, BuilderType>>, com.google.protobuf.GeneratedMessageLite.GeneratedExtension<ContainingType extends com.google.protobuf.MessageLite, Type>, com.google.protobuf.GeneratedMessageLite.MethodToInvoke, com.google.protobuf.GeneratedMessageLite.SerializedForm Nested classes/interfaces inherited from class com.google.protobuf.AbstractMessageLite
com.google.protobuf.AbstractMessageLite.InternalOneOfEnum -
Field Summary
FieldsModifier and TypeFieldDescriptionstatic final intstatic final intstatic final intstatic final intstatic final intstatic final intFields inherited from class com.google.protobuf.GeneratedMessageLite
unknownFieldsFields inherited from class com.google.protobuf.AbstractMessageLite
memoizedHashCode -
Method Summary
Modifier and TypeMethodDescriptionprotected final ObjectdynamicMethod(com.google.protobuf.GeneratedMessageLite.MethodToInvoke method, Object arg0, Object arg1) com.google.protobuf.BoolValue* A flag indicating this allowance applies to all tokens of the specified (non-fungible/unique) type.static NftAllowance* A spender-owner account identifier.<br/> This account identifier identifies a `spender` for whom an existing `approved_for_all` allowance was previously created.getOwner()* An owner account identifier.<br/> This is the account identifier of the account granting an allowance for the `spender` to transfer tokens held by this account.longgetSerialNumbers(int index) * A list of token serial numbers.<br/> The list of serial numbers that the spender is permitted to transfer.int* A list of token serial numbers.<br/> The list of serial numbers that the spender is permitted to transfer.* A list of token serial numbers.<br/> The list of serial numbers that the spender is permitted to transfer.* A spender account identifier.<br/> This is the account identifier of the account permitted to transfer tokens held by the `owner`.* A token identifier.<br/> This identifies the type of token the `spender` is permitted to transfer from the `owner`.boolean* A flag indicating this allowance applies to all tokens of the specified (non-fungible/unique) type.boolean* A spender-owner account identifier.<br/> This account identifier identifies a `spender` for whom an existing `approved_for_all` allowance was previously created.booleanhasOwner()* An owner account identifier.<br/> This is the account identifier of the account granting an allowance for the `spender` to transfer tokens held by this account.boolean* A spender account identifier.<br/> This is the account identifier of the account permitted to transfer tokens held by the `owner`.boolean* A token identifier.<br/> This identifies the type of token the `spender` is permitted to transfer from the `owner`.static NftAllowance.Builderstatic NftAllowance.BuildernewBuilder(NftAllowance prototype) static NftAllowanceparseDelimitedFrom(InputStream input) static NftAllowanceparseDelimitedFrom(InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) static NftAllowanceparseFrom(byte[] data) static NftAllowanceparseFrom(byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) static NftAllowanceparseFrom(com.google.protobuf.ByteString data) static NftAllowanceparseFrom(com.google.protobuf.ByteString data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) static NftAllowanceparseFrom(com.google.protobuf.CodedInputStream input) static NftAllowanceparseFrom(com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) static NftAllowanceparseFrom(InputStream input) static NftAllowanceparseFrom(InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) static NftAllowanceparseFrom(ByteBuffer data) static NftAllowanceparseFrom(ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) static com.google.protobuf.Parser<NftAllowance> parser()Methods inherited from class com.google.protobuf.GeneratedMessageLite
createBuilder, createBuilder, emptyBooleanList, emptyDoubleList, emptyFloatList, emptyIntList, emptyLongList, emptyProtobufList, equals, getDefaultInstanceForType, getParserForType, getSerializedSize, hashCode, isInitialized, makeImmutable, mergeLengthDelimitedField, mergeUnknownFields, mergeVarintField, mutableCopy, mutableCopy, mutableCopy, mutableCopy, mutableCopy, mutableCopy, newBuilderForType, newMessageInfo, newRepeatedGeneratedExtension, newSingularGeneratedExtension, parseDelimitedFrom, parseDelimitedFrom, parseFrom, parseFrom, parseFrom, parseFrom, parseFrom, parseFrom, parseFrom, parseFrom, parseFrom, parseFrom, parsePartialFrom, parseUnknownField, registerDefaultInstance, toBuilder, toString, writeToMethods inherited from class com.google.protobuf.AbstractMessageLite
addAll, checkByteStringIsUtf8, toByteArray, toByteString, writeDelimitedTo, writeToMethods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, wait, wait, waitMethods inherited from interface com.google.protobuf.MessageLiteOrBuilder
getDefaultInstanceForType, isInitialized
-
Field Details
-
TOKENID_FIELD_NUMBER
public static final int TOKENID_FIELD_NUMBER- See Also:
-
OWNER_FIELD_NUMBER
public static final int OWNER_FIELD_NUMBER- See Also:
-
SPENDER_FIELD_NUMBER
public static final int SPENDER_FIELD_NUMBER- See Also:
-
SERIAL_NUMBERS_FIELD_NUMBER
public static final int SERIAL_NUMBERS_FIELD_NUMBER- See Also:
-
APPROVED_FOR_ALL_FIELD_NUMBER
public static final int APPROVED_FOR_ALL_FIELD_NUMBER- See Also:
-
DELEGATING_SPENDER_FIELD_NUMBER
public static final int DELEGATING_SPENDER_FIELD_NUMBER- See Also:
-
-
Method Details
-
hasTokenId
public boolean hasTokenId()* A token identifier.<br/> This identifies the type of token the `spender` is permitted to transfer from the `owner`. <p> The identified token type MUST be a non-fungible/unique token.
.proto.TokenID tokenId = 1;- Specified by:
hasTokenIdin interfaceNftAllowanceOrBuilder- Returns:
- Whether the tokenId field is set.
-
getTokenId
* A token identifier.<br/> This identifies the type of token the `spender` is permitted to transfer from the `owner`. <p> The identified token type MUST be a non-fungible/unique token.
.proto.TokenID tokenId = 1;- Specified by:
getTokenIdin interfaceNftAllowanceOrBuilder- Returns:
- The tokenId.
-
hasOwner
public boolean hasOwner()* An owner account identifier.<br/> This is the account identifier of the account granting an allowance for the `spender` to transfer tokens held by this account.
.proto.AccountID owner = 2;- Specified by:
hasOwnerin interfaceNftAllowanceOrBuilder- Returns:
- Whether the owner field is set.
-
getOwner
* An owner account identifier.<br/> This is the account identifier of the account granting an allowance for the `spender` to transfer tokens held by this account.
.proto.AccountID owner = 2;- Specified by:
getOwnerin interfaceNftAllowanceOrBuilder- Returns:
- The owner.
-
hasSpender
public boolean hasSpender()* A spender account identifier.<br/> This is the account identifier of the account permitted to transfer tokens held by the `owner`.
.proto.AccountID spender = 3;- Specified by:
hasSpenderin interfaceNftAllowanceOrBuilder- Returns:
- Whether the spender field is set.
-
getSpender
* A spender account identifier.<br/> This is the account identifier of the account permitted to transfer tokens held by the `owner`.
.proto.AccountID spender = 3;- Specified by:
getSpenderin interfaceNftAllowanceOrBuilder- Returns:
- The spender.
-
getSerialNumbersList
* A list of token serial numbers.<br/> The list of serial numbers that the spender is permitted to transfer. <p> The `owner` MUST currently hold each token identified in this list.
repeated int64 serial_numbers = 4;- Specified by:
getSerialNumbersListin interfaceNftAllowanceOrBuilder- Returns:
- A list containing the serialNumbers.
-
getSerialNumbersCount
public int getSerialNumbersCount()* A list of token serial numbers.<br/> The list of serial numbers that the spender is permitted to transfer. <p> The `owner` MUST currently hold each token identified in this list.
repeated int64 serial_numbers = 4;- Specified by:
getSerialNumbersCountin interfaceNftAllowanceOrBuilder- Returns:
- The count of serialNumbers.
-
getSerialNumbers
public long getSerialNumbers(int index) * A list of token serial numbers.<br/> The list of serial numbers that the spender is permitted to transfer. <p> The `owner` MUST currently hold each token identified in this list.
repeated int64 serial_numbers = 4;- Specified by:
getSerialNumbersin interfaceNftAllowanceOrBuilder- Parameters:
index- The index of the element to return.- Returns:
- The serialNumbers at the given index.
-
hasApprovedForAll
public boolean hasApprovedForAll()* A flag indicating this allowance applies to all tokens of the specified (non-fungible/unique) type. <p> If true, the `spender` SHALL be permitted to transfer any or all of the `owner`'s tokens of the specified token type. This SHALL apply not only to currently owned tokens, but to all such tokens acquired in the future, unless the allowance is `delete`d.
.google.protobuf.BoolValue approved_for_all = 5;- Specified by:
hasApprovedForAllin interfaceNftAllowanceOrBuilder- Returns:
- Whether the approvedForAll field is set.
-
getApprovedForAll
public com.google.protobuf.BoolValue getApprovedForAll()* A flag indicating this allowance applies to all tokens of the specified (non-fungible/unique) type. <p> If true, the `spender` SHALL be permitted to transfer any or all of the `owner`'s tokens of the specified token type. This SHALL apply not only to currently owned tokens, but to all such tokens acquired in the future, unless the allowance is `delete`d.
.google.protobuf.BoolValue approved_for_all = 5;- Specified by:
getApprovedForAllin interfaceNftAllowanceOrBuilder- Returns:
- The approvedForAll.
-
hasDelegatingSpender
public boolean hasDelegatingSpender()* A spender-owner account identifier.<br/> This account identifier identifies a `spender` for whom an existing `approved_for_all` allowance was previously created. This enables an account with such broad access to grant allowances to transfer individual tokens from the original owner without involving that original owner. <p> If this is set, the account identified MUST sign this transaction, but the `owner` account MAY NOT sign this transaction.<br/> If this is set, there MUST exist an active `approved_for_all` allowance from the `owner` for the `delegating_spender` to transfer all tokens of the type identified by the `tokenId` field.<br/> If this value is set, the `approved_for_all` flag MUST be `false`.
.proto.AccountID delegating_spender = 6;- Specified by:
hasDelegatingSpenderin interfaceNftAllowanceOrBuilder- Returns:
- Whether the delegatingSpender field is set.
-
getDelegatingSpender
* A spender-owner account identifier.<br/> This account identifier identifies a `spender` for whom an existing `approved_for_all` allowance was previously created. This enables an account with such broad access to grant allowances to transfer individual tokens from the original owner without involving that original owner. <p> If this is set, the account identified MUST sign this transaction, but the `owner` account MAY NOT sign this transaction.<br/> If this is set, there MUST exist an active `approved_for_all` allowance from the `owner` for the `delegating_spender` to transfer all tokens of the type identified by the `tokenId` field.<br/> If this value is set, the `approved_for_all` flag MUST be `false`.
.proto.AccountID delegating_spender = 6;- Specified by:
getDelegatingSpenderin interfaceNftAllowanceOrBuilder- Returns:
- The delegatingSpender.
-
parseFrom
public static NftAllowance parseFrom(ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException - Throws:
com.google.protobuf.InvalidProtocolBufferException
-
parseFrom
public static NftAllowance parseFrom(ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException - Throws:
com.google.protobuf.InvalidProtocolBufferException
-
parseFrom
public static NftAllowance parseFrom(com.google.protobuf.ByteString data) throws com.google.protobuf.InvalidProtocolBufferException - Throws:
com.google.protobuf.InvalidProtocolBufferException
-
parseFrom
public static NftAllowance parseFrom(com.google.protobuf.ByteString data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException - Throws:
com.google.protobuf.InvalidProtocolBufferException
-
parseFrom
public static NftAllowance parseFrom(byte[] data) throws com.google.protobuf.InvalidProtocolBufferException - Throws:
com.google.protobuf.InvalidProtocolBufferException
-
parseFrom
public static NftAllowance parseFrom(byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException - Throws:
com.google.protobuf.InvalidProtocolBufferException
-
parseFrom
- Throws:
IOException
-
parseFrom
public static NftAllowance parseFrom(InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws IOException - Throws:
IOException
-
parseDelimitedFrom
- Throws:
IOException
-
parseDelimitedFrom
public static NftAllowance parseDelimitedFrom(InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws IOException - Throws:
IOException
-
parseFrom
- Throws:
IOException
-
parseFrom
public static NftAllowance parseFrom(com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws IOException - Throws:
IOException
-
newBuilder
-
newBuilder
-
dynamicMethod
protected final Object dynamicMethod(com.google.protobuf.GeneratedMessageLite.MethodToInvoke method, Object arg0, Object arg1) - Specified by:
dynamicMethodin classcom.google.protobuf.GeneratedMessageLite<NftAllowance,NftAllowance.Builder>
-
getDefaultInstance
-
parser
-