Class: Kippt::Saves

Inherits:
Object
  • Object
show all
Defined in:
lib/kippt/saves.rb

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(client, clip) ⇒ Saves

Returns a new instance of Saves.



6
7
8
9
# File 'lib/kippt/saves.rb', line 6

def initialize(client, clip)
  @client = client
  @clip   = clip
end

Instance Attribute Details

#clipObject (readonly)

Returns the value of attribute clip.



4
5
6
# File 'lib/kippt/saves.rb', line 4

def clip
  @clip
end

Instance Method Details

#collection_classObject



11
12
13
# File 'lib/kippt/saves.rb', line 11

def collection_class
  Kippt::UserCollection
end

#fetch(options = {}) ⇒ Object Also known as: all



15
16
17
# File 'lib/kippt/saves.rb', line 15

def fetch(options = {})
  collection_class.new({"objects" => @clip.saves_data}, client)
end