class ClassyStruct::ClassyStructClass

Public Instance Methods

lock() click to toggle source

Convert ClassyStruct to Struct, thus locking it.

# File ext/classystruct.rb, line 41
def lock
  self.to_h.to_struct(Struct::STRUCT_TYPE)
end
merge(other) click to toggle source
# File ext/classystruct.rb, line 36
def merge other
  self.to_h.merge!(other.to_h).to_struct(STRUCT_TYPE)
end
struct_type() click to toggle source
# File ext/classystruct.rb, line 32
def struct_type
  STRUCT_TYPE
end