Class: YouTube::Profile

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

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(payload) ⇒ Profile

Returns a new instance of Profile.



251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
# File 'lib/youtube.rb', line 251

def initialize(payload)
  @about_me = payload['about_me'].to_s
  @age = payload['age'].to_i
  @books = payload['books'].to_s
  @city = payload['city'].to_s
  @companies = payload['companies'].to_s
  @country = payload['country'].to_s
  @currently_on = YouTube._string_to_boolean(payload['currently_on'])
  @favorite_video_count = payload['favorite_video_count'].to_i
  @first_name = payload['first_name'].to_s
  @friend_count = payload['friend_count'].to_i
  @gender = payload['gender'].to_s
  @hobbies = payload['hobbies'].to_s
  @homepage = payload['homepage'].to_s
  @hometown = payload['hometown'].to_s
  @last_name = payload['last_name'].to_s
  @movies = payload['movies'].to_s
  @occupations = payload['occupations'].to_s
  @relationship = payload['relationship'].to_s
  @video_upload_count = payload['video_upload_count'].to_i
  @video_watch_count = payload['video_watch_count'].to_i
end

Instance Attribute Details

#about_meObject (readonly)

Returns the value of attribute about_me.



230
231
232
# File 'lib/youtube.rb', line 230

def about_me
  @about_me
end

#ageObject (readonly)

Returns the value of attribute age.



231
232
233
# File 'lib/youtube.rb', line 231

def age
  @age
end

#booksObject (readonly)

Returns the value of attribute books.



232
233
234
# File 'lib/youtube.rb', line 232

def books
  @books
end

#cityObject (readonly)

Returns the value of attribute city.



233
234
235
# File 'lib/youtube.rb', line 233

def city
  @city
end

#companiesObject (readonly)

Returns the value of attribute companies.



234
235
236
# File 'lib/youtube.rb', line 234

def companies
  @companies
end

#countryObject (readonly)

Returns the value of attribute country.



235
236
237
# File 'lib/youtube.rb', line 235

def country
  @country
end

#currently_onObject (readonly)

Returns the value of attribute currently_on.



236
237
238
# File 'lib/youtube.rb', line 236

def currently_on
  @currently_on
end

#favorite_video_countObject (readonly)

Returns the value of attribute favorite_video_count.



237
238
239
# File 'lib/youtube.rb', line 237

def favorite_video_count
  @favorite_video_count
end

#first_nameObject (readonly)

Returns the value of attribute first_name.



238
239
240
# File 'lib/youtube.rb', line 238

def first_name
  @first_name
end

#friend_countObject (readonly)

Returns the value of attribute friend_count.



239
240
241
# File 'lib/youtube.rb', line 239

def friend_count
  @friend_count
end

#genderObject (readonly)

Returns the value of attribute gender.



240
241
242
# File 'lib/youtube.rb', line 240

def gender
  @gender
end

#hobbiesObject (readonly)

Returns the value of attribute hobbies.



241
242
243
# File 'lib/youtube.rb', line 241

def hobbies
  @hobbies
end

#homepageObject (readonly)

Returns the value of attribute homepage.



242
243
244
# File 'lib/youtube.rb', line 242

def homepage
  @homepage
end

#hometownObject (readonly)

Returns the value of attribute hometown.



243
244
245
# File 'lib/youtube.rb', line 243

def hometown
  @hometown
end

#last_nameObject (readonly)

Returns the value of attribute last_name.



244
245
246
# File 'lib/youtube.rb', line 244

def last_name
  @last_name
end

#moviesObject (readonly)

Returns the value of attribute movies.



245
246
247
# File 'lib/youtube.rb', line 245

def movies
  @movies
end

#occupationsObject (readonly)

Returns the value of attribute occupations.



246
247
248
# File 'lib/youtube.rb', line 246

def occupations
  @occupations
end

#relationshipObject (readonly)

Returns the value of attribute relationship.



247
248
249
# File 'lib/youtube.rb', line 247

def relationship
  @relationship
end

#video_upload_countObject (readonly)

Returns the value of attribute video_upload_count.



248
249
250
# File 'lib/youtube.rb', line 248

def video_upload_count
  @video_upload_count
end

#video_watch_countObject (readonly)

Returns the value of attribute video_watch_count.



249
250
251
# File 'lib/youtube.rb', line 249

def video_watch_count
  @video_watch_count
end