Class: Hackmac::DiskInfo
Instance Attribute Summary collapse
-
#disk ⇒ Object
readonly
Returns the value of attribute disk.
Instance Method Summary collapse
-
#initialize(disk:) ⇒ DiskInfo
constructor
A new instance of DiskInfo.
Methods included from Plist
#as_hash, #method_missing, #plist, #to_json
Constructor Details
#initialize(disk:) ⇒ DiskInfo
Returns a new instance of DiskInfo.
7 8 9 10 |
# File 'lib/hackmac/disks.rb', line 7 def initialize(disk:) @disk = disk plist *(%w[ diskutil info -plist ] << disk) end |
Dynamic Method Handling
This class handles dynamic methods through the method_missing method in the class Hackmac::Plist
Instance Attribute Details
#disk ⇒ Object (readonly)
Returns the value of attribute disk.
12 13 14 |
# File 'lib/hackmac/disks.rb', line 12 def disk @disk end |