Class: BrickFTP::RESTfulAPI::GetFolderSize
- Inherits:
-
Object
- Object
- BrickFTP::RESTfulAPI::GetFolderSize
- Includes:
- Command
- Defined in:
- lib/brick_ftp/restful_api/get_folder_size.rb
Overview
Get folder size
Instance Method Summary collapse
-
#call(path) ⇒ Integer
Returns the size (in bytes) of the specified folder, recursively.
Methods included from Command
Instance Method Details
#call(path) ⇒ Integer
Returns the size (in bytes) of the specified folder, recursively.
19 20 21 22 |
# File 'lib/brick_ftp/restful_api/get_folder_size.rb', line 19 def call(path) res = client.get("/api/rest/v1/folders/#{ERB::Util.url_encode(path)}?action=size") res['data']['size'] end |