java.lang.Object
com.google.protobuf.AbstractMessageLite<File,File.Builder>
com.google.protobuf.GeneratedMessageLite<File,File.Builder>
com.hedera.hashgraph.sdk.proto.File
- All Implemented Interfaces:
com.google.protobuf.MessageLite,com.google.protobuf.MessageLiteOrBuilder,FileOrBuilder
@Generated
public final class File
extends com.google.protobuf.GeneratedMessageLite<File,File.Builder>
implements FileOrBuilder
* Representation of an Hedera File Service `file`. Files offer a place to store additional data, much more than is available in other entities, for use with smart contracts, non-fungible tokens, etc... As with all network entities, a file has a unique entity number, which is given along with the network's shard and realm in the form of a shard.realm.number id.Protobuf type
proto.File-
Nested Class Summary
Nested ClassesModifier and TypeClassDescriptionstatic final class* Representation of an Hedera File Service `file`.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 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.ByteString* The contents of the file.static Fileboolean* A flag indicating that this file is deleted.long* The file's expiration time in seconds since the epoch.<br/> This value should be compared against consensus time, which may not exactly match clock time at the moment of expiration.* This file's ID within the global network state.getKeys()* A list of keys that MUST sign any transaction to create or update this file.getMemo()* A short description of the file.com.google.protobuf.ByteString* A short description of the file.long* The pre-system-delete expiration time of a deleted "system" file, in seconds.boolean* This file's ID within the global network state.booleanhasKeys()* A list of keys that MUST sign any transaction to create or update this file.static File.Builderstatic File.BuildernewBuilder(File prototype) static FileparseDelimitedFrom(InputStream input) static FileparseDelimitedFrom(InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) static FileparseFrom(byte[] data) static FileparseFrom(byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) static FileparseFrom(com.google.protobuf.ByteString data) static FileparseFrom(com.google.protobuf.ByteString data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) static FileparseFrom(com.google.protobuf.CodedInputStream input) static FileparseFrom(com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) static FileparseFrom(InputStream input) static FileparseFrom(InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) static FileparseFrom(ByteBuffer data) static FileparseFrom(ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) static com.google.protobuf.Parser<File> 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
-
FILE_ID_FIELD_NUMBER
public static final int FILE_ID_FIELD_NUMBER- See Also:
-
EXPIRATION_SECOND_FIELD_NUMBER
public static final int EXPIRATION_SECOND_FIELD_NUMBER- See Also:
-
KEYS_FIELD_NUMBER
public static final int KEYS_FIELD_NUMBER- See Also:
-
CONTENTS_FIELD_NUMBER
public static final int CONTENTS_FIELD_NUMBER- See Also:
-
MEMO_FIELD_NUMBER
public static final int MEMO_FIELD_NUMBER- See Also:
-
DELETED_FIELD_NUMBER
public static final int DELETED_FIELD_NUMBER- See Also:
-
PRE_SYSTEM_DELETE_EXPIRATION_SECOND_FIELD_NUMBER
public static final int PRE_SYSTEM_DELETE_EXPIRATION_SECOND_FIELD_NUMBER- See Also:
-
-
Method Details
-
hasFileId
public boolean hasFileId()* This file's ID within the global network state. <p> This value SHALL be unique within the network.
.proto.FileID file_id = 1;- Specified by:
hasFileIdin interfaceFileOrBuilder- Returns:
- Whether the fileId field is set.
-
getFileId
* This file's ID within the global network state. <p> This value SHALL be unique within the network.
.proto.FileID file_id = 1;- Specified by:
getFileIdin interfaceFileOrBuilder- Returns:
- The fileId.
-
getExpirationSecond
public long getExpirationSecond()* The file's expiration time in seconds since the epoch.<br/> This value should be compared against consensus time, which may not exactly match clock time at the moment of expiration. <p> For this purpose, `epoch` SHALL be the UNIX epoch with 0 at `1970-01-01T00:00:00.000Z`.
int64 expiration_second = 2;- Specified by:
getExpirationSecondin interfaceFileOrBuilder- Returns:
- The expirationSecond.
-
hasKeys
public boolean hasKeys()* A list of keys that MUST sign any transaction to create or update this file. <p> Only _one_ of these keys must sign a transaction to delete the file.<br/> This field MAY be `null` or an empty list.<br/> If this field is null or an empty `KeyList`, then the file SHALL be immutable.<br/> For an immutable file, the only transaction permitted to modify that file SHALL be a `fileUpdate` transaction with _only_ the `expirationTime` set.
.proto.KeyList keys = 3;- Specified by:
hasKeysin interfaceFileOrBuilder- Returns:
- Whether the keys field is set.
-
getKeys
* A list of keys that MUST sign any transaction to create or update this file. <p> Only _one_ of these keys must sign a transaction to delete the file.<br/> This field MAY be `null` or an empty list.<br/> If this field is null or an empty `KeyList`, then the file SHALL be immutable.<br/> For an immutable file, the only transaction permitted to modify that file SHALL be a `fileUpdate` transaction with _only_ the `expirationTime` set.
.proto.KeyList keys = 3;- Specified by:
getKeysin interfaceFileOrBuilder- Returns:
- The keys.
-
getContents
public com.google.protobuf.ByteString getContents()* The contents of the file. <p> This SHALL be limited to the current maximum file size; typically no more than 1 Megabyte (1048576 bytes).
bytes contents = 4;- Specified by:
getContentsin interfaceFileOrBuilder- Returns:
- The contents.
-
getMemo
* A short description of the file. <p> This value, if set, MUST NOT exceed `transaction.maxMemoUtf8Bytes` (default 100) bytes when encoded as UTF-8.
string memo = 5;- Specified by:
getMemoin interfaceFileOrBuilder- Returns:
- The memo.
-
getMemoBytes
public com.google.protobuf.ByteString getMemoBytes()* A short description of the file. <p> This value, if set, MUST NOT exceed `transaction.maxMemoUtf8Bytes` (default 100) bytes when encoded as UTF-8.
string memo = 5;- Specified by:
getMemoBytesin interfaceFileOrBuilder- Returns:
- The bytes for memo.
-
getDeleted
public boolean getDeleted()* A flag indicating that this file is deleted. <p> The `contents` of a deleted "regular" file SHALL be an empty (zero length) bytes.
bool deleted = 6;- Specified by:
getDeletedin interfaceFileOrBuilder- Returns:
- The deleted.
-
getPreSystemDeleteExpirationSecond
public long getPreSystemDeleteExpirationSecond()* The pre-system-delete expiration time of a deleted "system" file, in seconds. <p> This field SHALL contain the original expiration time of a "system" file that is deleted. This SHOULD be used to restore that expiration time if the file is subsequently "un-deleted" before it is purged from the system.<br/> A "regular" file cannot be "un-deleted", so this field SHALL NOT be set for those files.
int64 pre_system_delete_expiration_second = 7;- Specified by:
getPreSystemDeleteExpirationSecondin interfaceFileOrBuilder- Returns:
- The preSystemDeleteExpirationSecond.
-
parseFrom
public static File parseFrom(ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException - Throws:
com.google.protobuf.InvalidProtocolBufferException
-
parseFrom
public static File parseFrom(ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException - Throws:
com.google.protobuf.InvalidProtocolBufferException
-
parseFrom
public static File parseFrom(com.google.protobuf.ByteString data) throws com.google.protobuf.InvalidProtocolBufferException - Throws:
com.google.protobuf.InvalidProtocolBufferException
-
parseFrom
public static File parseFrom(com.google.protobuf.ByteString data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException - Throws:
com.google.protobuf.InvalidProtocolBufferException
-
parseFrom
- Throws:
com.google.protobuf.InvalidProtocolBufferException
-
parseFrom
public static File parseFrom(byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException - Throws:
com.google.protobuf.InvalidProtocolBufferException
-
parseFrom
- Throws:
IOException
-
parseFrom
public static File parseFrom(InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws IOException - Throws:
IOException
-
parseDelimitedFrom
- Throws:
IOException
-
parseDelimitedFrom
public static File parseDelimitedFrom(InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws IOException - Throws:
IOException
-
parseFrom
- Throws:
IOException
-
parseFrom
public static File 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<File,File.Builder>
-
getDefaultInstance
-
parser
-