Class: SchemaTest::Property::Float

Inherits:
SchemaTest::Property show all
Defined in:
lib/schema_test/property.rb

Instance Attribute Summary

Attributes inherited from SchemaTest::Property

#description, #name, #optional, #type

Instance Method Summary collapse

Methods inherited from SchemaTest::Property

#==, #as_json_schema, #as_structure, #json_schema_format, #optional!, #optional?

Constructor Details

#initialize(name, description = nil) ⇒ Float

Returns a new instance of Float.



63
64
65
# File 'lib/schema_test/property.rb', line 63

def initialize(name, description=nil)
  super(name, :float, description)
end

Instance Method Details

#json_schema_typeObject



67
68
69
# File 'lib/schema_test/property.rb', line 67

def json_schema_type
  'number'
end