Class AbstractConsumerStore
java.lang.Object
org.eclipse.lyo.server.oauth.core.consumer.AbstractConsumerStore
- All Implemented Interfaces:
ConsumerStore
- Direct Known Subclasses:
FileSystemConsumerStore
,RdfConsumerStore
Manages the list of OAuth consumers.
- Author:
- Samuel Padgett
-
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptionprotected LyoOAuthConsumer
add
(LyoOAuthConsumer consumer) void
addAll
(Collection<LyoOAuthConsumer> consumers) abstract void
Closes the consumer store.Gets all OAuth consumers.getConsumer
(String consumerKey) Gets the consumer for a key.getConsumer
(net.oauth.OAuthMessage requestMessage) Gets the consumer for this message.protected LyoOAuthConsumer
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
Methods inherited from interface org.eclipse.lyo.server.oauth.core.consumer.ConsumerStore
addConsumer, removeConsumer, updateConsumer
-
Constructor Details
-
AbstractConsumerStore
public AbstractConsumerStore()
-
-
Method Details
-
addAll
-
getAllConsumers
Description copied from interface:ConsumerStore
Gets all OAuth consumers.- Specified by:
getAllConsumers
in interfaceConsumerStore
- Returns:
- all OAuth consumers, provisional and approved
-
getConsumer
public LyoOAuthConsumer getConsumer(net.oauth.OAuthMessage requestMessage) throws net.oauth.OAuthException, IOException Description copied from interface:ConsumerStore
Gets the consumer for this message.- Specified by:
getConsumer
in interfaceConsumerStore
- Parameters:
requestMessage
- the OAuth message- Returns:
- the consumer
- Throws:
net.oauth.OAuthException
- if the OAuth message does not contain a consumer keyConsumerStoreException
- on other errorsIOException
- on errors reading the message
-
getConsumer
Description copied from interface:ConsumerStore
Gets the consumer for a key.- Specified by:
getConsumer
in interfaceConsumerStore
- Parameters:
consumerKey
- the consumer key- Returns:
- the consumer or null if there is no consumer for this key
-
closeConsumerStore
public abstract void closeConsumerStore()Description copied from interface:ConsumerStore
Closes the consumer store. It is unavailable for further use.- Specified by:
closeConsumerStore
in interfaceConsumerStore
-
add
-
remove
-