Class: Spacer::User
- Inherits:
-
Object
show all
- Includes:
- Model
- Defined in:
- lib/spacer/models/user.rb
Instance Attribute Summary collapse
Class Method Summary
collapse
Instance Method Summary
collapse
Methods included from Model
included, #initialize, #populate, #populate_from_hash!, #populated?
Instance Attribute Details
#__type ⇒ Object
Returns the value of attribute __type.
4
5
6
|
# File 'lib/spacer/models/user.rb', line 4
def __type
@__type
end
|
#client ⇒ Object
Returns the value of attribute client.
5
6
7
|
# File 'lib/spacer/models/user.rb', line 5
def client
@client
end
|
#image ⇒ Object
Returns the value of attribute image.
4
5
6
|
# File 'lib/spacer/models/user.rb', line 4
def image
@image
end
|
#name ⇒ Object
Returns the value of attribute name.
4
5
6
|
# File 'lib/spacer/models/user.rb', line 4
def name
@name
end
|
#onlineNow ⇒ Object
Returns the value of attribute onlineNow.
4
5
6
|
# File 'lib/spacer/models/user.rb', line 4
def onlineNow
@onlineNow
end
|
#uri ⇒ Object
Returns the value of attribute uri.
4
5
6
|
# File 'lib/spacer/models/user.rb', line 4
def uri
@uri
end
|
#userId ⇒ Object
Returns the value of attribute userId.
4
5
6
|
# File 'lib/spacer/models/user.rb', line 4
def userId
@userId
end
|
#userType ⇒ Object
Returns the value of attribute userType.
4
5
6
|
# File 'lib/spacer/models/user.rb', line 4
def userType
@userType
end
|
#webUri ⇒ Object
Returns the value of attribute webUri.
4
5
6
|
# File 'lib/spacer/models/user.rb', line 4
def webUri
@webUri
end
|
Class Method Details
.from_hash_with_client(hash, client) ⇒ Object
8
9
10
11
12
|
# File 'lib/spacer/models/user.rb', line 8
def from_hash_with_client(hash, client)
instance = new(hash)
instance.client = client
instance
end
|
Instance Method Details
#album(album_id) ⇒ Object
29
30
31
|
# File 'lib/spacer/models/user.rb', line 29
def album(album_id)
@client.album(userId, album_id)
end
|
#albums ⇒ Object
25
26
27
|
# File 'lib/spacer/models/user.rb', line 25
def albums
@client.albums(userId)
end
|
#details ⇒ Object
45
46
47
|
# File 'lib/spacer/models/user.rb', line 45
def details
@client.details(userId)
end
|
#friends(page = nil, page_size = nil, list = nil) ⇒ Object
21
22
23
|
# File 'lib/spacer/models/user.rb', line 21
def friends(page=nil, page_size=nil, list=nil)
@client.friends(userId, page, page_size, list)
end
|
#friends_with?(friends_ids) ⇒ Boolean
69
70
71
|
# File 'lib/spacer/models/user.rb', line 69
def friends_with?(friends_ids)
@client.friendship?(userId, friend_ids)
end
|
#groups ⇒ Object
73
74
75
|
# File 'lib/spacer/models/user.rb', line 73
def groups
@client.groups(userId)
end
|
#interests ⇒ Object
41
42
43
|
# File 'lib/spacer/models/user.rb', line 41
def interests
@client.interests(userId)
end
|
#mood ⇒ Object
65
66
67
|
# File 'lib/spacer/models/user.rb', line 65
def mood
@client.mood(userId)
end
|
#photo(photo_id) ⇒ Object
57
58
59
|
# File 'lib/spacer/models/user.rb', line 57
def photo(photo_id)
@client.photo(userId, photo_id)
end
|
#photos ⇒ Object
37
38
39
|
# File 'lib/spacer/models/user.rb', line 37
def photos
@client.photos(userId)
end
|
#photos_for_album(album_id) ⇒ Object
33
34
35
|
# File 'lib/spacer/models/user.rb', line 33
def photos_for_album(album_id)
@client.photos_for_album(userId, album_id)
end
|
#profile ⇒ Object
These are helper methods to access client calls if you already have a user instance
17
18
19
|
# File 'lib/spacer/models/user.rb', line 17
def profile
@client.profile(userId)
end
|
#status ⇒ Object
61
62
63
|
# File 'lib/spacer/models/user.rb', line 61
def status
@client.status(userId)
end
|
#video(video_id) ⇒ Object
53
54
55
|
# File 'lib/spacer/models/user.rb', line 53
def video(video_id)
@client.video(userId, video_id)
end
|
#videos ⇒ Object
49
50
51
|
# File 'lib/spacer/models/user.rb', line 49
def videos
@client.videos(userId)
end
|