java.lang.Object
org.kohsuke.github.GHObject
org.kohsuke.github.GHPerson
- Direct Known Subclasses:
GHOrganization
,GHUser
Common part of
GHUser
and GHOrganization
.- Author:
- Kohsuke Kawaguchi
-
Field Summary
Modifier and TypeFieldDescriptionprotected String
The avatar url.protected String
The twitter username.protected String
The twitter username.protected String
The twitter username.protected String
The twitter username.protected int
The public gists.protected int
The public gists.protected boolean
The hireable.protected String
The html url.protected String
The twitter username.protected String
The avatar url.protected String
The twitter username.protected int
The public gists.protected int
The public gists.protected boolean
The hireable.protected Integer
The total private repos.protected String
The twitter username.protected String
The twitter username.Fields inherited from class org.kohsuke.github.GHObject
responseHeaderFields
-
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptionReturns a string of the avatar image URL.getBlog()
Gets the blog URL of this user.Gets the company name of this user, like "Sun Microsystems, Inc."Gets the created at.getEmail()
Gets the e-mail address of the user.int
Gets followers count.int
Gets following count.Gets the html url.Gets the location of this user, like "Santa Clara, California".getLogin()
Gets the login ID of this user, like 'kohsuke'.getName()
Gets the human-readable name of the user, like "Kohsuke Kawaguchi".int
Gets public gist count.int
Gets public repo count.Gets the public repositories this user owns.getRepository
(String name) Gets repository.Gets total private repo count.Gets the Twitter Username of this user, like "GitHub".getType()
Gets the type.Gets the updated at.boolean
Gets the site_admin field.abstract PagedIterable<GHEventInfo>
Lists events for an organization or an user.List all the repositories using a default of 30 items page size.listRepositories
(int pageSize) Deprecated.Use #listRepositories().withPageSize() instead.protected void
populate()
Fully populate the data by retrieving missing data.Methods inherited from class org.kohsuke.github.GHObject
getId, getNodeId, getResponseHeaderFields, getUrl, setResponseHeaderFields, toString
-
Field Details
-
login
The avatar url. -
avatar_url
The avatar url. -
location
The twitter username. -
blog
The twitter username. -
email
The twitter username. -
bio
The twitter username. -
name
The twitter username. -
company
The twitter username. -
type
The twitter username. -
twitter_username
The twitter username. -
html_url
The html url. -
followers
protected int followersThe public gists. -
following
protected int followingThe public gists. -
public_repos
protected int public_reposThe public gists. -
public_gists
protected int public_gistsThe public gists. -
site_admin
protected boolean site_adminThe hireable. -
hireable
protected boolean hireableThe hireable. -
total_private_repos
The total private repos.
-
-
Constructor Details
-
GHPerson
public GHPerson()Create default GHPerson instance
-
-
Method Details
-
populate
Fully populate the data by retrieving missing data.Depending on the original API call where this object is created, it may not contain everything.
- Throws:
IOException
- the io exception
-
getRepositories
Gets the public repositories this user owns.To list your own repositories, including private repositories, use
GHMyself.listRepositories()
- Returns:
- the repositories
- Throws:
IOException
- the io exception
-
listRepositories
List all the repositories using a default of 30 items page size.Unlike
getRepositories()
, this does not wait until all the repositories are returned.- Returns:
- the paged iterable
-
listRepositories
Deprecated.Use #listRepositories().withPageSize() instead.Lists up all the repositories using the specified page size.- Parameters:
pageSize
- size for each page of items returned by GitHub. Maximum page size is 100. UnlikegetRepositories()
, this does not wait until all the repositories are returned.- Returns:
- the paged iterable
-
getRepository
Gets repository.- Parameters:
name
- the name- Returns:
- null if the repository was not found
- Throws:
IOException
- the io exception
-
listEvents
Lists events for an organization or an user.- Returns:
- the paged iterable
- Throws:
IOException
- the io exception
-
getAvatarUrl
Returns a string of the avatar image URL.- Returns:
- the avatar url
-
getLogin
Gets the login ID of this user, like 'kohsuke'.- Returns:
- the login
-
getName
Gets the human-readable name of the user, like "Kohsuke Kawaguchi".- Returns:
- the name
- Throws:
IOException
- the io exception
-
getCompany
Gets the company name of this user, like "Sun Microsystems, Inc."- Returns:
- the company
- Throws:
IOException
- the io exception
-
getLocation
Gets the location of this user, like "Santa Clara, California".- Returns:
- the location
- Throws:
IOException
- the io exception
-
getTwitterUsername
Gets the Twitter Username of this user, like "GitHub".- Returns:
- the Twitter username
- Throws:
IOException
- the io exception
-
getCreatedAt
Gets the created at.- Overrides:
getCreatedAt
in classGHObject
- Returns:
- the created at
- Throws:
IOException
- Signals that an I/O exception has occurred.
-
getUpdatedAt
Gets the updated at.- Overrides:
getUpdatedAt
in classGHObject
- Returns:
- the updated at
- Throws:
IOException
- Signals that an I/O exception has occurred.
-
getBlog
Gets the blog URL of this user.- Returns:
- the blog
- Throws:
IOException
- the io exception
-
getHtmlUrl
Gets the html url.- Returns:
- the html url
-
getEmail
Gets the e-mail address of the user.- Returns:
- the email
- Throws:
IOException
- the io exception
-
getPublicGistCount
Gets public gist count.- Returns:
- the public gist count
- Throws:
IOException
- the io exception
-
getPublicRepoCount
Gets public repo count.- Returns:
- the public repo count
- Throws:
IOException
- the io exception
-
getFollowingCount
Gets following count.- Returns:
- the following count
- Throws:
IOException
- the io exception
-
getFollowersCount
Gets followers count.- Returns:
- the followers count
- Throws:
IOException
- the io exception
-
getType
Gets the type. This is either "User" or "Organization".- Returns:
- the type
- Throws:
IOException
- the io exception
-
isSiteAdmin
Gets the site_admin field.- Returns:
- the site_admin field
- Throws:
IOException
- the io exception
-
getTotalPrivateRepoCount
Gets total private repo count.- Returns:
- the total private repo count
- Throws:
IOException
- the io exception
-