Class: Rmega::Nodes::File
- Includes:
- Deletable, Downloadable
- Defined in:
- lib/rmega/nodes/file.rb
Instance Attribute Summary
Attributes inherited from Node
Instance Method Summary collapse
Methods included from Downloadable
#allocate, #decrypt_chunk, #download, #download_chunk, #write_chunk
Methods included from Deletable
Methods inherited from Node
#attributes, #decrypted_file_key, #file_key, #file_keys, #handle, #initialize, #name, #parent_handle, #process_shared_key, #public_handle, #public_url, #public_url=, #shared_root?, #type
Methods included from Traversable
#children, #empty?, #files, #folders, #parent
Methods included from Loggable
Constructor Details
This class inherits a constructor from Rmega::Nodes::Node
Instance Method Details
#filesize ⇒ Object
19 20 21 |
# File 'lib/rmega/nodes/file.rb', line 19 def filesize size end |
#size ⇒ Object
15 16 17 |
# File 'lib/rmega/nodes/file.rb', line 15 def size data['s'] end |
#storage_url ⇒ Object
11 12 13 |
# File 'lib/rmega/nodes/file.rb', line 11 def storage_url @storage_url ||= data['g'] || request(a: 'g', g: 1, n: handle)['g'] end |