Class: Fluent::Json::Schema::Terms::Date

Inherits:
Str
  • Object
show all
Defined in:
lib/fluent/json/schema/terms/date.rb

Instance Attribute Summary

Attributes inherited from Str

#max_length, #min_length, #pattern

Attributes inherited from Field

#constraints, #default, #enum, #name, #required, #version

Instance Method Summary collapse

Methods inherited from Str

#as_json, #datetime, #email, #set, #uri

Methods inherited from Field

#as_json, #mandate, #optionalise, #set

Constructor Details

#initialize(name) ⇒ Date

Returns a new instance of Date.



6
7
8
9
# File 'lib/fluent/json/schema/terms/date.rb', line 6

def initialize(name)
  super(name)
  self.datetime
end

Instance Method Details

#formatObject



11
12
13
# File 'lib/fluent/json/schema/terms/date.rb', line 11

def format
  return :'date-time'
end