Class: Model

Inherits:
Object
  • Object
show all
Defined in:
lib/jenson/model.rb

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(name, fields) ⇒ Model

Returns a new instance of Model.



14
15
16
17
18
19
# File 'lib/jenson/model.rb', line 14

def initialize(name, fields)
  if name.empty? || fields.empty?
    return
  end
  
end

Instance Attribute Details

#fieldsObject

Returns the value of attribute fields.



12
13
14
# File 'lib/jenson/model.rb', line 12

def fields
  @fields
end

#nameObject

Returns the value of attribute name.



11
12
13
# File 'lib/jenson/model.rb', line 11

def name
  @name
end