Class: CC::Yaml::Nodes::Root
- Defined in:
- lib/cc/yaml/nodes/root.rb
Instance Attribute Summary
Attributes inherited from Mapping
Attributes inherited from Node
Instance Method Summary collapse
- #exclude?(path) ⇒ Boolean
-
#initialize ⇒ Root
constructor
A new instance of Root.
- #inspect ⇒ Object
- #nested_warnings ⇒ Object
- #rate?(path) ⇒ Boolean
Methods inherited from Mapping
#==, #[], #[]=, #accept_key?, aliases, #check_duplicates, #deep_verify, define_map_accessor, #each_scalar, #empty?, #include?, map, #mapped_key, mapping, #prepare, required, #set_warnings, #subnode_for, subnode_for, #verify, #verify_errors, #verify_required, #visit_key_value, #visit_mapping, #visit_pair, #with_value!
Methods inherited from Node
#deep_verify, #dup, #error, #errors, #errors?, has_default?, #method_missing, #nested_warning, #prepare, #respond_to_missing?, #to_json, #to_s, #verify, #visit_child, #visit_mapping, #visit_pair, #visit_scalar, #visit_sequence, #visit_unexpected, #warning, #warnings, #warnings?, #with_value
Constructor Details
#initialize ⇒ Root
Returns a new instance of Root.
12 13 14 |
# File 'lib/cc/yaml/nodes/root.rb', line 12 def initialize super(nil) end |
Dynamic Method Handling
This class handles dynamic methods through the method_missing method in the class CC::Yaml::Nodes::Node
Instance Method Details
#exclude?(path) ⇒ Boolean
24 25 26 |
# File 'lib/cc/yaml/nodes/root.rb', line 24 def exclude?(path) exclude_paths.present? && exclude_paths.match_any?(path) end |
#inspect ⇒ Object
20 21 22 |
# File 'lib/cc/yaml/nodes/root.rb', line 20 def inspect "#<#{self.class.name}:#{super}>" end |
#nested_warnings ⇒ Object
16 17 18 |
# File 'lib/cc/yaml/nodes/root.rb', line 16 def nested_warnings(*) super.uniq end |
#rate?(path) ⇒ Boolean
28 29 30 |
# File 'lib/cc/yaml/nodes/root.rb', line 28 def rate?(path) .present? && .rate?(path) end |