Module: Geni::Taggable

Included in:
Document, Photo, Video
Defined in:
lib/geni/taggable.rb

Instance Method Summary collapse

Instance Method Details

#tagObject

Raises:

  • (NotImplementedError)


19
20
21
# File 'lib/geni/taggable.rb', line 19

def tag
  raise NotImplementedError
end

#tagsObject



3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
# File 'lib/geni/taggable.rb', line 3

def tags
  return @tags if @tags
  
  response_hash = client.access_token.get("/api/#{id}/tags")
  
  if response_hash.has_key?('results')
    profile_ids = response_hash['results'].collect do |profile|
      profile['id']
    end

    @tags = client.get_profiles(profile_ids)
  else
    @tags = []
  end
end

#untagObject

Raises:

  • (NotImplementedError)


23
24
25
# File 'lib/geni/taggable.rb', line 23

def untag
  raise NotImplementedError
end