Module: MetasploitDataModels::Match::Parent::ClassMethods
- Defined in:
- lib/metasploit_data_models/match/parent.rb
Overview
Instance Method Summary collapse
-
#match_child_names ⇒ Array<String>
Class#namefor classes that extend Child and should be tested usingmatch. -
#match_children ⇒ Array<String>
Classes on which to callmatchin #match_child. -
#match_children_named(class_names) ⇒ Array<String>
Register the given
class_namesasClass#names for children classes for #match_child.
Instance Method Details
#match_child_names ⇒ Array<String>
Class#name for classes that extend Child and should be tested using match.
62 63 64 |
# File 'lib/metasploit_data_models/match/parent.rb', line 62 def match_child_names @match_child_names ||= [] end |
#match_children ⇒ Array<String>
Classes on which to call match in MetasploitDataModels::Match::Parent#match_child
69 70 71 |
# File 'lib/metasploit_data_models/match/parent.rb', line 69 def match_children @match_children ||= match_child_names.map(&:constantize) end |
#match_children_named(class_names) ⇒ Array<String>
Note:
Classes named class_names
Register the given class_names as Class#names for children classes for
MetasploitDataModels::Match::Parent#match_child.
78 79 80 |
# File 'lib/metasploit_data_models/match/parent.rb', line 78 def match_children_named(class_names) @match_child_names = class_names end |