パッケージ twitter4j
クラス OAuth2Authorization
java.lang.Object
twitter4j.OAuth2Authorization
- すべての実装されたインタフェース:
Serializable,Authorization
-
ネストされたクラスの概要
ネストされたクラス -
メソッドの概要
修飾子とタイプメソッド説明booleangetAuthorizationHeader(twitter4j.HttpRequest req) static OAuth2AuthorizationEquivalent to OAuth2Authorization.newBuilder().build();static OAuth2AuthorizationgetInstance(String consumerKey, String consumerSecret) Equivalent to OAuth2Authorization.newBuilder().oAuthConsumer(key, secret).build();Obtains an OAuth 2 Bearer token.inthashCode()voidRevokes an issued OAuth 2 Bearer Token.booleanReturns true if authorization credentials are set.toString()
-
メソッドの詳細
-
newBuilder
- 戻り値:
- builder for
OAuth2Authorization
-
getInstance
Equivalent to OAuth2Authorization.newBuilder().oAuthConsumer(key, secret).build();- パラメータ:
consumerKey- consumer keyconsumerSecret- consumer secret- 戻り値:
- OAuth2Authorization
-
getInstance
Equivalent to OAuth2Authorization.newBuilder().build();- 戻り値:
- OAuth2Authorization
-
getOAuth2Token
Obtains an OAuth 2 Bearer token.- 戻り値:
- OAuth 2 Bearer token
- 例外:
TwitterException- when Twitter service or network is unavailable, or connecting non-SSL endpoints.IllegalStateException- when Bearer token is already available, or OAuth consumer is not available.- 関連項目:
-
invalidateOAuth2Token
Revokes an issued OAuth 2 Bearer Token.- 例外:
TwitterException- when Twitter service or network is unavailable, or connecting non-SSL endpoints.IllegalStateException- when Bearer token is not available.
-
getAuthorizationHeader
- 定義:
getAuthorizationHeaderインタフェース内Authorization- パラメータ:
req- request- 戻り値:
- header
-
isEnabled
public boolean isEnabled()インタフェースからコピーされた説明:AuthorizationReturns true if authorization credentials are set.- 定義:
isEnabledインタフェース内Authorization- 戻り値:
- true if authorization credentials are set
-
equals
-
hashCode
public int hashCode() -
toString
-