Class: Reflekt::ObjectMeta

Inherits:
Meta
  • Object
show all
Defined in:
lib/meta/object_meta.rb

Instance Method Summary collapse

Methods inherited from Meta

deserialize, numeric?

Constructor Details

#initializeObjectMeta

Returns a new instance of ObjectMeta.


15
16
17
18
# File 'lib/meta/object_meta.rb', line 15

def initialize()
  @type = :object
  @class_type = nil
end

Instance Method Details

#load(value) ⇒ Object

Parameters:

  • value (Dynamic)

    Any custom class.


23
24
25
# File 'lib/meta/object_meta.rb', line 23

def load(value)
  @class_type = value.class
end

#serializeObject


27
28
29
30
31
32
# File 'lib/meta/object_meta.rb', line 27

def serialize()
  {
    :type => @type,
    :class_type => @class_type
  }
end