Class: LicenseAcceptance::Strategy::Environment
- Defined in:
- lib/license_acceptance/strategy/environment.rb
Overview
Look for acceptance values in the environment
Instance Attribute Summary collapse
-
#env ⇒ Object
readonly
Returns the value of attribute env.
Instance Method Summary collapse
- #accepted? ⇒ Boolean
-
#initialize(env) ⇒ Environment
constructor
A new instance of Environment.
- #no_persist? ⇒ Boolean
- #silent? ⇒ Boolean
Constructor Details
#initialize(env) ⇒ Environment
Returns a new instance of Environment.
11 12 13 |
# File 'lib/license_acceptance/strategy/environment.rb', line 11 def initialize(env) @env = env end |
Instance Attribute Details
#env ⇒ Object (readonly)
Returns the value of attribute env.
9 10 11 |
# File 'lib/license_acceptance/strategy/environment.rb', line 9 def env @env end |
Instance Method Details
#accepted? ⇒ Boolean
15 16 17 |
# File 'lib/license_acceptance/strategy/environment.rb', line 15 def accepted? look_for_value(ACCEPT) end |
#no_persist? ⇒ Boolean
23 24 25 |
# File 'lib/license_acceptance/strategy/environment.rb', line 23 def no_persist? look_for_value(ACCEPT_NO_PERSIST) end |
#silent? ⇒ Boolean
19 20 21 |
# File 'lib/license_acceptance/strategy/environment.rb', line 19 def silent? look_for_value(ACCEPT_SILENT) end |