Class: ForemanMaintain::Utils::Disk::IO::FileSystem
- Inherits:
-
Object
- Object
- ForemanMaintain::Utils::Disk::IO::FileSystem
- Includes:
- Concerns::SystemHelpers
- Defined in:
- lib/foreman_maintain/utils/disk/io/file_system.rb
Instance Attribute Summary collapse
-
#dir ⇒ Object
Returns the value of attribute dir.
-
#name ⇒ Object
Returns the value of attribute name.
Instance Method Summary collapse
-
#initialize(dir, name = '') ⇒ FileSystem
constructor
A new instance of FileSystem.
- #read_speed ⇒ Object
- #unit ⇒ Object
Methods included from Concerns::SystemHelpers
#check_min_version, #clean_all_packages, #downstream_installation?, #execute, #execute!, #execute?, #file_exists?, #find_package, #hostname, included, #package_version, #packages_action, #parse_csv, #parse_json, #rpm_version, #server?, #shellescape, #smart_proxy?, #version
Methods included from Concerns::Logger
Constructor Details
#initialize(dir, name = '') ⇒ FileSystem
Returns a new instance of FileSystem.
10 11 12 13 |
# File 'lib/foreman_maintain/utils/disk/io/file_system.rb', line 10 def initialize(dir, name = '') @dir = dir @name = name end |
Instance Attribute Details
#dir ⇒ Object
Returns the value of attribute dir.
8 9 10 |
# File 'lib/foreman_maintain/utils/disk/io/file_system.rb', line 8 def dir @dir end |
#name ⇒ Object
Returns the value of attribute name.
8 9 10 |
# File 'lib/foreman_maintain/utils/disk/io/file_system.rb', line 8 def name @name end |
Instance Method Details
#read_speed ⇒ Object
15 16 17 |
# File 'lib/foreman_maintain/utils/disk/io/file_system.rb', line 15 def read_speed @read_speed ||= convert_kb_to_mb(fio) end |
#unit ⇒ Object
19 20 21 |
# File 'lib/foreman_maintain/utils/disk/io/file_system.rb', line 19 def unit @unit ||= 'MB/sec' end |