class LicenseAcceptance::Strategy::ProvidedValue

Used for library consumers to parse their own form of acceptance (knife config, omnibus config, etc.) and pass it in

Attributes

value[R]

Public Class Methods

new(value) click to toggle source
# File lib/license_acceptance/strategy/provided_value.rb, line 10
def initialize(value)
  @value = value
end

Public Instance Methods

accepted?() click to toggle source
# File lib/license_acceptance/strategy/provided_value.rb, line 14
def accepted?
  String(value).downcase == ACCEPT
end
no_persist?() click to toggle source
# File lib/license_acceptance/strategy/provided_value.rb, line 22
def no_persist?
  String(value).downcase == ACCEPT_NO_PERSIST
end
silent?() click to toggle source
# File lib/license_acceptance/strategy/provided_value.rb, line 18
def silent?
  String(value).downcase == ACCEPT_SILENT
end
value?() click to toggle source
# File lib/license_acceptance/strategy/provided_value.rb, line 26
def value?
  !!value
end