Package de.coho04.githubapi.entities
Klasse GHUser
java.lang.Object
de.coho04.githubapi.bases.GHBase
de.coho04.githubapi.bases.ClassBase
de.coho04.githubapi.bases.EntityBase
de.coho04.githubapi.entities.GHUser
- Alle implementierten Schnittstellen:
HttpRequestInterface,JSONHelper
- Bekannte direkte Unterklassen:
SelfUser
Represents a GitHub user.
This class provides methods and properties to access information about a user on GitHub.
-
Verschachtelte Klassen - Übersicht
Von Schnittstelle geerbte verschachtelte Klassen/Schnittstellen de.coho04.githubapi.interfaces.JSONHelper
JSONHelper.JSONToObject<T> -
Feldübersicht
Felder -
Konstruktorübersicht
Konstruktoren -
Methodenübersicht
Modifizierer und TypMethodeBeschreibungfindRepositoryByName(String name) Finds and returns a repository by its name for the current user.intReturns the number of contributions made by this user.Fetches and returns a list of users who are followers of the current user.Returns the URL for fetching the followers of this user.Fetches and returns a list of users who the current user is following.Returns the URL for fetching the users followed by this user.Returns the URL for fetching the gists of this user.Returns the gravatar ID of this user.Returns the URL for fetching the organizations of this user.Fetches and returns a list of public keys associated with the current user.Returns the URL for fetching the events received by this user.Returns the URL for fetching the repositories starred by this user.Returns the URL for fetching the subscriptions of this user.static GHUserFetches a GitHub user by their username.booleanReturns whether this user is a site administrator.org.json.JSONObjectConverts this user instance to a JSONObject.Von Klasse geerbte Methoden de.coho04.githubapi.bases.EntityBase
getAvatarUrl, getLogin, getReposUrl, getType, getUsernameVon Klasse geerbte Methoden de.coho04.githubapi.bases.ClassBase
getEventsUrl, getHtmlUrl, getId, getNodeId, getUrlVon Klasse geerbte Methoden de.coho04.githubapi.bases.GHBase
fetchArrayData, fetchArrayData, fetchPaginatedData, fetchPaginatedData, fetchPaginatedData, getBaseUrlVon Klasse geerbte Methoden java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitVon Schnittstelle geerbte Methoden de.coho04.githubapi.interfaces.HttpRequestInterface
extractNextPageUrl, sendDeleteRequest, sendDeleteRequestWithResponseCode, sendGetRequest, sendGetRequestWithLinkHeader, sendGetRequestWithResponseCode, sendPatchRequest, sendPostRequest, sendPutRequestVon Schnittstelle geerbte Methoden de.coho04.githubapi.interfaces.JSONHelper
getArrayOrNull, getBooleanOrNull, getIntOrNull, getJSONArrayToStringList, getJSONObjectOrNull, getLocalDateOrNull, getLongOrNull, getStringOrNull
-
Felddetails
-
github
-
-
Konstruktordetails
-
GHUser
Constructs a new GHUser instance with the provided JSON object.- Parameter:
jsonObject- the JSON object containing the user data
-
-
Methodendetails
-
toJSONObject
public org.json.JSONObject toJSONObject()Converts this user instance to a JSONObject.- Setzt außer Kraft:
toJSONObjectin KlasseEntityBase- Gibt zurück:
- a JSONObject representation of this user
-
getUser
Fetches a GitHub user by their username.- Parameter:
github- the GitHub instancename- the username of the user to fetch- Gibt zurück:
- a GHUser instance representing the fetched user
-
getFollowersUrl
Returns the URL for fetching the followers of this user.- Gibt zurück:
- the followers URL
-
getFollowingUrl
Returns the URL for fetching the users followed by this user.- Gibt zurück:
- the following URL
-
getGistsUrl
Returns the URL for fetching the gists of this user.- Gibt zurück:
- the gists URL
-
getReceivedEventsUrl
Returns the URL for fetching the events received by this user.- Gibt zurück:
- the received events URL
-
getStarredUrl
Returns the URL for fetching the repositories starred by this user.- Gibt zurück:
- the starred URL
-
getSubscriptionsUrl
Returns the URL for fetching the subscriptions of this user.- Gibt zurück:
- the subscriptions URL
-
getGravatarId
Returns the gravatar ID of this user.- Gibt zurück:
- the gravatar ID
-
getOrganizationsUrl
Returns the URL for fetching the organizations of this user.- Gibt zurück:
- the organizations URL
-
getContributions
public int getContributions()Returns the number of contributions made by this user.- Gibt zurück:
- the number of contributions
-
isSiteAdmin
public boolean isSiteAdmin()Returns whether this user is a site administrator.- Gibt zurück:
- true if the user is a site administrator, false otherwise
-
findRepositoryByName
Finds and returns a repository by its name for the current user.- Parameter:
name- the name of the repository to find- Gibt zurück:
- the GHRepository instance representing the found repository
-
getFollowers
Fetches and returns a list of users who are followers of the current user.- Gibt zurück:
- a list of GHUser instances representing the followers of the current user
-
getFollowing
Fetches and returns a list of users who the current user is following.- Gibt zurück:
- a list of GHUser instances representing the users the current user is following
-
getPublicKeys
Fetches and returns a list of public keys associated with the current user.- Gibt zurück:
- a list of GHPublicKey instances representing the public keys of the current user
-
listRepositories
-