lib/tdlib/client_methods.rb
def read_file_part(file_id:, offset:, count:)
    broadcast('@type'   => 'readFilePart',
              'file_id' => file_id,
              'offset'  => offset,
              'count'   => count)
  end
# Reads a part of a file from the TDLib file cache and returns read bytes.
# This method is intended to be used only if the application has no direct access to TDLib's file system, because it
#   is usually slower than a direct read from the file.
#
# @param file_id [Integer] Identifier of the file.
#   The file must be located in the TDLib file cache.
# @param offset [Integer] The offset from which to read the file.
# @param count [Integer] Number of bytes to read.
#   An error will be returned if there are not enough bytes available in the file from the specified position.
#   Pass 0 to read all available data from the specified position.
# @return [TD::Types::FilePart]
Reads a part of a file from the TDLib file cache and returns read bytes.
This method is intended to be used only if the application has no direct access to TDLib's file system, because it
is usually slower than a direct read from the file.
Reads a part of a file from the TDLib file cache and returns read bytes . This method is intended to be used only if the application has no direct access to TDLib ' s file system because it is usually slower than a direct read from the file .
def read_file_part(file_id:, offset:, count:)
    broadcast('@type'   => 'readFilePart',
              'file_id' => file_id,
              'offset'  => offset,
              'count'   => count)
  end
def read_file_part ( file_id : , offset : , count : ) broadcast ( '@type' => 'readFilePart' , 'file_id' => file_id , 'offset' => offset , 'count' => count ) end
Reads a part of a file from the TDLib file cache and returns read bytes.
Reads a part of a file from the TDLib file cache and returns read bytes .
None
TD::Types::FilePart
file_id
Identifier of the file. The file must be located in the TDLib file cache.
Identifier of the file . The file must be located in the TDLib file cache .
offset
The offset from which to read the file.
The offset from which to read the file .
count
Number of bytes to read. An error will be returned if there are not enough bytes available in the file from the specified position. Pass 0 to read all available data from the specified position.
Number of bytes to read . An error will be returned if there are not enough bytes available in the file from the specified position . Pass 0 to read all available data from the specified position .