Class: Sfp::Unknown
- Inherits:
-
Object
- Object
- Sfp::Unknown
- Defined in:
- lib/sfp/Sfplib.rb
Overview
Instance of this class will be return as the value of an unknown variable in open-world assumption.
Instance Attribute Summary collapse
-
#path ⇒ Object
Returns the value of attribute path.
-
#type ⇒ Object
Returns the value of attribute type.
Class Method Summary collapse
Instance Method Summary collapse
-
#initialize(path = nil, type = nil) ⇒ Unknown
constructor
A new instance of Unknown.
- #to_s ⇒ Object
Constructor Details
#initialize(path = nil, type = nil) ⇒ Unknown
Returns a new instance of Unknown.
202 203 204 205 |
# File 'lib/sfp/Sfplib.rb', line 202 def initialize(path=nil, type=nil) @path = path @type = type end |
Instance Attribute Details
#path ⇒ Object
Returns the value of attribute path.
201 202 203 |
# File 'lib/sfp/Sfplib.rb', line 201 def path @path end |
#type ⇒ Object
Returns the value of attribute type.
201 202 203 |
# File 'lib/sfp/Sfplib.rb', line 201 def type @type end |
Class Method Details
Instance Method Details
#to_s ⇒ Object
207 208 209 |
# File 'lib/sfp/Sfplib.rb', line 207 def to_s (@type.nil? ? "$.Unknown" : "$.Unknown.#{@type}") end |