Class: GithubSearch::User
- Defined in:
- lib/github-search/user.rb
Instance Attribute Summary collapse
-
#avatar_url ⇒ Object
readonly
Returns the value of attribute avatar_url.
-
#events_url ⇒ Object
readonly
Returns the value of attribute events_url.
-
#followers_url ⇒ Object
readonly
Returns the value of attribute followers_url.
-
#following_url ⇒ Object
readonly
Returns the value of attribute following_url.
-
#gists_url ⇒ Object
readonly
Returns the value of attribute gists_url.
-
#gravatar_id ⇒ Object
readonly
Returns the value of attribute gravatar_id.
-
#html_url ⇒ Object
readonly
Returns the value of attribute html_url.
-
#id ⇒ Object
readonly
Returns the value of attribute id.
-
#login ⇒ Object
readonly
Returns the value of attribute login.
-
#organizations_url ⇒ Object
readonly
Returns the value of attribute organizations_url.
-
#received_events_url ⇒ Object
readonly
Returns the value of attribute received_events_url.
-
#repos_url ⇒ Object
readonly
Returns the value of attribute repos_url.
-
#score ⇒ Object
readonly
Returns the value of attribute score.
-
#site_admin ⇒ Object
readonly
Returns the value of attribute site_admin.
-
#starred_url ⇒ Object
readonly
Returns the value of attribute starred_url.
-
#subscriptions_url ⇒ Object
readonly
Returns the value of attribute subscriptions_url.
-
#type ⇒ Object
readonly
Returns the value of attribute type.
-
#url ⇒ Object
readonly
Returns the value of attribute url.
Class Method Summary collapse
Instance Method Summary collapse
-
#initialize(attributes) ⇒ User
constructor
A new instance of User.
Methods inherited from Searcher
#issues, #repos, #search, #users
Constructor Details
#initialize(attributes) ⇒ User
Returns a new instance of User.
25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 |
# File 'lib/github-search/user.rb', line 25 def initialize(attributes) @id = attributes["id"] @login = attributes["login"] @avatar_url = attributes["avatar_url"] @gravatar_id = attributes["gravatar_id"] @url = attributes["url"] @html_url = attributes["html_url"] @followers_url = attributes["followers_url"] @following_url = attributes["following_url"] @gists_url = attributes["gists_url"] @starred_url = attributes["starred_url"] @subscriptions_url = attributes["subscriptions_url"] @organizations_url = attributes["organizations_url"] @repos_url = attributes["repos_url"] @events_url = attributes["events_url"] @received_events_url = attributes["received_events_url"] @type = attributes["type"] @site_admin = attributes["site_admin"] @score = attributes["score"] end |
Instance Attribute Details
#avatar_url ⇒ Object (readonly)
Returns the value of attribute avatar_url.
6 7 8 |
# File 'lib/github-search/user.rb', line 6 def avatar_url @avatar_url end |
#events_url ⇒ Object (readonly)
Returns the value of attribute events_url.
6 7 8 |
# File 'lib/github-search/user.rb', line 6 def events_url @events_url end |
#followers_url ⇒ Object (readonly)
Returns the value of attribute followers_url.
6 7 8 |
# File 'lib/github-search/user.rb', line 6 def followers_url @followers_url end |
#following_url ⇒ Object (readonly)
Returns the value of attribute following_url.
6 7 8 |
# File 'lib/github-search/user.rb', line 6 def following_url @following_url end |
#gists_url ⇒ Object (readonly)
Returns the value of attribute gists_url.
6 7 8 |
# File 'lib/github-search/user.rb', line 6 def gists_url @gists_url end |
#gravatar_id ⇒ Object (readonly)
Returns the value of attribute gravatar_id.
6 7 8 |
# File 'lib/github-search/user.rb', line 6 def gravatar_id @gravatar_id end |
#html_url ⇒ Object (readonly)
Returns the value of attribute html_url.
6 7 8 |
# File 'lib/github-search/user.rb', line 6 def html_url @html_url end |
#id ⇒ Object (readonly)
Returns the value of attribute id.
6 7 8 |
# File 'lib/github-search/user.rb', line 6 def id @id end |
#login ⇒ Object (readonly)
Returns the value of attribute login.
6 7 8 |
# File 'lib/github-search/user.rb', line 6 def login @login end |
#organizations_url ⇒ Object (readonly)
Returns the value of attribute organizations_url.
6 7 8 |
# File 'lib/github-search/user.rb', line 6 def organizations_url @organizations_url end |
#received_events_url ⇒ Object (readonly)
Returns the value of attribute received_events_url.
6 7 8 |
# File 'lib/github-search/user.rb', line 6 def received_events_url @received_events_url end |
#repos_url ⇒ Object (readonly)
Returns the value of attribute repos_url.
6 7 8 |
# File 'lib/github-search/user.rb', line 6 def repos_url @repos_url end |
#score ⇒ Object (readonly)
Returns the value of attribute score.
6 7 8 |
# File 'lib/github-search/user.rb', line 6 def score @score end |
#site_admin ⇒ Object (readonly)
Returns the value of attribute site_admin.
6 7 8 |
# File 'lib/github-search/user.rb', line 6 def site_admin @site_admin end |
#starred_url ⇒ Object (readonly)
Returns the value of attribute starred_url.
6 7 8 |
# File 'lib/github-search/user.rb', line 6 def starred_url @starred_url end |
#subscriptions_url ⇒ Object (readonly)
Returns the value of attribute subscriptions_url.
6 7 8 |
# File 'lib/github-search/user.rb', line 6 def subscriptions_url @subscriptions_url end |
#type ⇒ Object (readonly)
Returns the value of attribute type.
6 7 8 |
# File 'lib/github-search/user.rb', line 6 def type @type end |
#url ⇒ Object (readonly)
Returns the value of attribute url.
6 7 8 |
# File 'lib/github-search/user.rb', line 6 def url @url end |
Class Method Details
.sort_options ⇒ Object
46 47 48 |
# File 'lib/github-search/user.rb', line 46 def self. [:followers, :repositories, :joined] end |