Module: Brandish::Processor::PairFilter
- Defined in:
- lib/brandish/processor/pair_filter.rb
Overview
A filter for defining which pairs are accepted by the given command or block processor. By default, all pairs are restricted; however, certain pairs can be whitelisted, or all pairs can be allowed. The former helps with debugging.
Defined Under Namespace
Modules: ClassMethods, InstanceMethods
Constant Summary collapse
- ALL =
A placehodler object to denote that all pairs are allowed in the pair set. This is only inserted into the allowed pair set when ClassMethods#unrestricted_pairs! is called.
Object.new.freeze
Class Method Summary collapse
-
.included(receiver) ⇒ Object
private
Used as a hook for Ruby.
Class Method Details
.included(receiver) ⇒ Object
This method is part of a private API. You should avoid using this method if possible, as it may be removed or be changed in the future.
Used as a hook for Ruby.
90 91 92 93 |
# File 'lib/brandish/processor/pair_filter.rb', line 90 def self.included(receiver) receiver.extend ClassMethods receiver.send :include, InstanceMethods end |