Module: Interrogative::ClassMethods
- Includes:
- BaseMethods
- Defined in:
- lib/interrogative.rb
Overview
Methods tailored to the class level.
These handle inheritance of questions.
Instance Method Summary collapse
-
#questions ⇒ Array<Question>
Get the array of all noted questions for this class and its superclasses.
Methods included from BaseMethods
#postprocess_question, #question, #when_questioned
Instance Method Details
#questions ⇒ Array<Question>
Get the array of all noted questions for this class and its superclasses.
62 63 64 65 66 67 |
# File 'lib/interrogative.rb', line 62 def questions qs = [] qs |= superclass.questions if superclass.respond_to? :questions qs |= (@_questions||=[]) qs end |