Class: Whatlang::Info
- Inherits:
-
Object
- Object
- Whatlang::Info
- Defined in:
- lib/whatlang.rb
Instance Attribute Summary collapse
-
#confidence ⇒ Object
readonly
Returns the value of attribute confidence.
-
#lang ⇒ Object
readonly
Returns the value of attribute lang.
-
#script ⇒ Object
readonly
Returns the value of attribute script.
Instance Method Summary collapse
-
#initialize(lang, script, is_reliable, confidence) ⇒ Info
constructor
A new instance of Info.
- #reliable? ⇒ Boolean
Constructor Details
#initialize(lang, script, is_reliable, confidence) ⇒ Info
Returns a new instance of Info.
28 29 30 31 32 33 |
# File 'lib/whatlang.rb', line 28 def initialize(lang, script, is_reliable, confidence) @lang = lang @script = script @is_reliable = is_reliable @confidence = confidence end |
Instance Attribute Details
#confidence ⇒ Object (readonly)
Returns the value of attribute confidence.
26 27 28 |
# File 'lib/whatlang.rb', line 26 def confidence @confidence end |
#lang ⇒ Object (readonly)
Returns the value of attribute lang.
26 27 28 |
# File 'lib/whatlang.rb', line 26 def lang @lang end |
#script ⇒ Object (readonly)
Returns the value of attribute script.
26 27 28 |
# File 'lib/whatlang.rb', line 26 def script @script end |
Instance Method Details
#reliable? ⇒ Boolean
35 36 37 |
# File 'lib/whatlang.rb', line 35 def reliable? @is_reliable end |