Class TdApi.RemoteFile

  • Enclosing class:
    TdApi

    public static class TdApi.RemoteFile
    extends TdApi.Object
    Represents a remote file.
    • Field Summary

      Fields 
      Modifier and Type Field Description
      static int CONSTRUCTOR
      Identifier uniquely determining type of the object.
      java.lang.String id
      Remote file identifier, may be empty.
      boolean isUploadingActive
      True, if the file is currently being uploaded (or a remote copy is being generated by some other means).
      boolean isUploadingCompleted
      True, if a remote copy is fully available.
      int uploadedSize
      Size of the remote available part of the file; 0 if unknown.
    • Constructor Summary

      Constructors 
      Constructor Description
      RemoteFile()
      Default constructor.
      RemoteFile​(java.lang.String id, boolean isUploadingActive, boolean isUploadingCompleted, int uploadedSize)
      Constructor for initialization of all fields.
    • Field Detail

      • id

        public java.lang.String id
        Remote file identifier, may be empty. Can be used across application restarts or even from other devices for the current user. If the ID starts with "http://" or "https://", it represents the HTTP URL of the file. TDLib is currently unable to download files if only their URL is known. If downloadFile is called on such a file or if it is sent to a secret chat, TDLib starts a file generation process by sending updateFileGenerationStart to the client with the HTTP URL in the originalPath and "#url#" as the conversion string. Clients should generate the file by downloading it to the specified location.
      • isUploadingActive

        public boolean isUploadingActive
        True, if the file is currently being uploaded (or a remote copy is being generated by some other means).
      • isUploadingCompleted

        public boolean isUploadingCompleted
        True, if a remote copy is fully available.
      • uploadedSize

        public int uploadedSize
        Size of the remote available part of the file; 0 if unknown.
      • CONSTRUCTOR

        public static final int CONSTRUCTOR
        Identifier uniquely determining type of the object.
        See Also:
        Constant Field Values
    • Constructor Detail

      • RemoteFile

        public RemoteFile()
        Default constructor.
      • RemoteFile

        public RemoteFile​(java.lang.String id,
                          boolean isUploadingActive,
                          boolean isUploadingCompleted,
                          int uploadedSize)
        Constructor for initialization of all fields.
        Parameters:
        id - Remote file identifier, may be empty. Can be used across application restarts or even from other devices for the current user. If the ID starts with "http://" or "https://", it represents the HTTP URL of the file. TDLib is currently unable to download files if only their URL is known. If downloadFile is called on such a file or if it is sent to a secret chat, TDLib starts a file generation process by sending updateFileGenerationStart to the client with the HTTP URL in the originalPath and "#url#" as the conversion string. Clients should generate the file by downloading it to the specified location.
        isUploadingActive - True, if the file is currently being uploaded (or a remote copy is being generated by some other means).
        isUploadingCompleted - True, if a remote copy is fully available.
        uploadedSize - Size of the remote available part of the file; 0 if unknown.