Class: Schemacop::V3::SymbolNode

Inherits:
Node
  • Object
show all
Defined in:
lib/schemacop/v3/symbol_node.rb

Instance Attribute Summary

Attributes inherited from Node

#as, #default, #description, #name, #options, #parent, #require_key, #title

Class Method Summary collapse

Instance Method Summary collapse

Methods inherited from Node

#cast, #children, #create, create, dsl_methods, #dsl_node, #dsl_scm, #init, #initialize, #require_key?, #required?, resolve_class, #schemas, supports_children, supports_children_options, #used_external_schemas, #validate

Constructor Details

This class inherits a constructor from Schemacop::V3::Node

Class Method Details

.allowed_optionsObject



12
13
14
# File 'lib/schemacop/v3/symbol_node.rb', line 12

def self.allowed_options
  super + %i[cast_str]
end

Instance Method Details

#allowed_typesObject



8
9
10
# File 'lib/schemacop/v3/symbol_node.rb', line 8

def allowed_types
  { Symbol => 'Symbol' }
end

#as_jsonObject



4
5
6
# File 'lib/schemacop/v3/symbol_node.rb', line 4

def as_json
  {} # Not supported by Json Schema
end