Class: OsDetector

Inherits:
Object
  • Object
show all
Includes:
Singleton
Defined in:
lib/facter/framework/detector/os_detector.rb

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(*_args) ⇒ OsDetector

Returns a new instance of OsDetector.



10
11
12
13
14
# File 'lib/facter/framework/detector/os_detector.rb', line 10

def initialize(*_args)
  @log = Facter::Log.new(self)
  @os_hierarchy = Facter::OsHierarchy.new
  @identifier = detect
end

Instance Attribute Details

#hierarchyObject (readonly)

Returns the value of attribute hierarchy.



8
9
10
# File 'lib/facter/framework/detector/os_detector.rb', line 8

def hierarchy
  @hierarchy
end

#identifierObject (readonly)

Returns the value of attribute identifier.



8
9
10
# File 'lib/facter/framework/detector/os_detector.rb', line 8

def identifier
  @identifier
end

#versionObject (readonly)

Returns the value of attribute version.



8
9
10
# File 'lib/facter/framework/detector/os_detector.rb', line 8

def version
  @version
end