Class: Vodka::Server::Relation

Inherits:
Object
  • Object
show all
Defined in:
lib/vodka/server/relation.rb

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(klass, params) ⇒ Relation

Returns a new instance of Relation.



6
7
8
9
10
11
12
13
14
# File 'lib/vodka/server/relation.rb', line 6

def initialize(klass, params)
  @klass = klass
  @relation = klass
  @params = params
  @data = []
  @metadata = {}

  convert!
end

Instance Attribute Details

#dataObject

Returns the value of attribute data.



4
5
6
# File 'lib/vodka/server/relation.rb', line 4

def data
  @data
end

#klassObject

Returns the value of attribute klass.



4
5
6
# File 'lib/vodka/server/relation.rb', line 4

def klass
  @klass
end

#metadataObject

Returns the value of attribute metadata.



4
5
6
# File 'lib/vodka/server/relation.rb', line 4

def 
  @metadata
end

#paramsObject

Returns the value of attribute params.



4
5
6
# File 'lib/vodka/server/relation.rb', line 4

def params
  @params
end

#relationObject

Returns the value of attribute relation.



4
5
6
# File 'lib/vodka/server/relation.rb', line 4

def relation
  @relation
end