Class: Plist4r::PlistType::Launchd::MachServices
- Defined in:
- lib/plist4r/plist_type/launchd.rb
Defined Under Namespace
Classes: MachService
Constant Summary
Constants included from DataMethods
DataMethods::ClassesForKeyType, DataMethods::ValidKeys, DataMethods::ValidKeysTemplate
Instance Method Summary collapse
Methods inherited from ArrayDict
#hash, #initialize, #select, #select_all, #to_hash, #unselect, #unselect_all
Methods included from DataMethods
#_respond_to?, #method_missing, #set_or_return, #set_or_return_of_type, #validate_value
Constructor Details
This class inherits a constructor from Plist4r::ArrayDict
Dynamic Method Handling
This class handles dynamic methods through the method_missing method in the class Plist4r::DataMethods
Instance Method Details
#add(service, value = nil, &blk) ⇒ Object
418 419 420 421 422 423 424 425 426 427 428 |
# File 'lib/plist4r/plist_type/launchd.rb', line 418 def add service, value=nil, &blk if value @hash[service] = value set_or_return_of_type :bool, service, value elsif blk @hash[service] = ::Plist4r::OrderedHash.new @hash[service] = MachServices::MachService.new(@hash[service],&blk).to_hash else @orig end end |