Class UserAPI
java.lang.Object
edu.sustech.search.engine.github.API.RestAPI
edu.sustech.search.engine.github.API.UserAPI
-
Field Summary
Fields inherited from class edu.sustech.search.engine.github.API.RestAPI
TIME_OUT_DURATION
-
Method Summary
Modifier and TypeMethodDescriptiongetStarredRepo
(User user) getStarredRepo
(String username) getStarredRepo
(URI uri) getUserInfoRaw
(String username) static UserAPI
registerAPI
(String... OAuthTokens) Register a new UserAPI based on OAuthTokens providedstatic UserAPI
registerAPI
(List<String> OAuthTokens) Register a new UserAPI based on OAuthTokens providedsendUserRequest
(String username) sendUserRequestDirect
(URI uri) Methods inherited from class edu.sustech.search.engine.github.API.RestAPI
addToken, convert, getHttpResponse, getHttpResponse, getHttpResponseLoopFetching, getHttpResponseLoopFetching, getHttpResponseLoopFetching, getHttpResponseLoopFetching, getHttpResponseRaw, getHttpResponseRaw, getHttpResponseRawLoopFetching, getHttpResponseRawLoopFetching, getHttpResponseRawLoopFetching, getHttpResponseRawLoopFetching, getNextToken, getRateLimit, getTokenCursor, parseEndPageCount, printRateLimit, setSuppressRateError, setSuppressResponseError, setTokenCursor
-
Method Details
-
getStarredRepo
public List<Entry<Repository,Date>> getStarredRepo(String username) throws IOException, InterruptedException - Throws:
IOException
InterruptedException
-
getStarredRepo
public List<Entry<Repository,Date>> getStarredRepo(User user) throws IOException, InterruptedException - Throws:
IOException
InterruptedException
-
getStarredRepo
public List<Entry<Repository,Date>> getStarredRepo(URI uri) throws IOException, InterruptedException - Throws:
IOException
InterruptedException
-
getUser
- Throws:
IOException
InterruptedException
-
getUser
- Throws:
IOException
InterruptedException
-
getUserInfoRaw
- Throws:
IOException
InterruptedException
-
sendUserRequest
public HttpResponse<String> sendUserRequest(String username) throws IOException, InterruptedException - Throws:
IOException
InterruptedException
-
sendUserRequestDirect
- Throws:
IOException
InterruptedException
-
registerAPI
Register a new UserAPI based on OAuthTokens provided- Parameters:
OAuthTokens
- Arrays of OAuthTokens- Returns:
-
registerAPI
Register a new UserAPI based on OAuthTokens provided- Parameters:
OAuthTokens
- List of OAuthTokens- Returns:
-