Package net.oauth
Class OAuthAccessor
- java.lang.Object
-
- net.oauth.OAuthAccessor
-
- All Implemented Interfaces:
Serializable
,Cloneable
public class OAuthAccessor extends Object implements Cloneable, Serializable
Properties of one User of an OAuthConsumer. Properties may be added freely, e.g. to support extensions.- Author:
- John Kristian
- See Also:
- Serialized Form
-
-
Field Summary
Fields Modifier and Type Field Description String
accessToken
OAuthConsumer
consumer
String
requestToken
String
tokenSecret
-
Constructor Summary
Constructors Constructor Description OAuthAccessor(OAuthConsumer consumer)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description OAuthAccessor
clone()
Object
getProperty(String name)
OAuthMessage
newRequestMessage(String method, String url, Collection<? extends Map.Entry<String,String>> parameters)
OAuthMessage
newRequestMessage(String method, String url, Collection<? extends Map.Entry<String,String>> parameters, InputStream body)
Construct a request message containing the given parameters but no body.void
setProperty(String name, Object value)
-
-
-
Field Detail
-
accessToken
public String accessToken
-
consumer
public final OAuthConsumer consumer
-
requestToken
public String requestToken
-
tokenSecret
public String tokenSecret
-
-
Constructor Detail
-
OAuthAccessor
public OAuthAccessor(OAuthConsumer consumer)
-
-
Method Detail
-
clone
public OAuthAccessor clone()
-
newRequestMessage
public OAuthMessage newRequestMessage(String method, String url, Collection<? extends Map.Entry<String,String>> parameters) throws OAuthException, IOException, URISyntaxException
-
newRequestMessage
public OAuthMessage newRequestMessage(String method, String url, Collection<? extends Map.Entry<String,String>> parameters, InputStream body) throws OAuthException, IOException, URISyntaxException
Construct a request message containing the given parameters but no body. Don't send the message, merely construct it. The caller will ordinarily send it, for example by calling OAuthClient.invoke or access.- Parameters:
method
- the HTTP request method. If this is null, use the default method; that is getProperty("httpMethod") or (if that's null) consumer.getProperty("httpMethod") or (if that's null) OAuthMessage.GET.- Throws:
OAuthException
IOException
URISyntaxException
-
-