module Conferrable
This is the main module that contains the class-level methods that define the main API.
Copyright © 2018-present, Blue Marble Payroll, LLC
This source code is licensed under the MIT license found in the LICENSE file in the root directory of this source tree.
Copyright © 2018-present, Blue Marble Payroll, LLC
This source code is licensed under the MIT license found in the LICENSE file in the root directory of this source tree.
Copyright © 2018-present, Blue Marble Payroll, LLC
This source code is licensed under the MIT license found in the LICENSE file in the root directory of this source tree.
Copyright © 2018-present, Blue Marble Payroll, LLC
This source code is licensed under the MIT license found in the LICENSE file in the root directory of this source tree.
Copyright © 2018-present, Blue Marble Payroll, LLC
This source code is licensed under the MIT license found in the LICENSE file in the root directory of this source tree.
Constants
- GET_PREFIX_MATCHER_REGEX
- GET_PREFIX_REGEX
- VERSION
Public Class Methods
# File lib/conferrable/conferrable.rb, line 34 def [](key) get(key) end
# File lib/conferrable/conferrable.rb, line 24 def clear! @entries = {} nil end
# File lib/conferrable/conferrable.rb, line 42 def entry(key) clear! unless @entries @entries[key.to_s] = Entry.new(key) unless @entries[key.to_s] @entries[key.to_s] end
# File lib/conferrable/conferrable.rb, line 38 def get(key) entry(key).all end
# File lib/conferrable/conferrable.rb, line 50 def method_missing(method_sym, *arguments, &block) if method_sym.to_s =~ GET_PREFIX_MATCHER_REGEX get(keyify(method_sym)) else super end end
# File lib/conferrable/conferrable.rb, line 58 def respond_to_missing?(method_sym, include_private = false) method_sym.to_s =~ GET_PREFIX_MATCHER_REGEX || super end
# File lib/conferrable/conferrable.rb, line 30 def set_filenames(key, filenames) entry(key).filenames = filenames end
Private Class Methods
# File lib/conferrable/conferrable.rb, line 64 def keyify(val) val.to_s.sub(GET_PREFIX_REGEX, '') end