Class PersistentServiceProviderConsumerStore
java.lang.Object
com.atlassian.bitbucket.jenkins.internal.applink.oauth.serviceprovider.AbstractPersistentStore<Consumer>
com.atlassian.bitbucket.jenkins.internal.applink.oauth.serviceprovider.consumer.PersistentServiceProviderConsumerStore
- All Implemented Interfaces:
ServiceProviderConsumerStore,Saveable,OnMaster
@Singleton
public class PersistentServiceProviderConsumerStore
extends AbstractPersistentStore<Consumer>
implements ServiceProviderConsumerStore
A
ServiceProviderConsumerStore implementation that persists the consumers to an XML file
Only one instance of this class must be created per Jenkins instance.
-
Field Summary
Fields inherited from class com.atlassian.bitbucket.jenkins.internal.applink.oauth.serviceprovider.AbstractPersistentStore
entityMap, xStream -
Constructor Summary
Constructors -
Method Summary
Methods inherited from class com.atlassian.bitbucket.jenkins.internal.applink.oauth.serviceprovider.AbstractPersistentStore
decrypt, encrypt, getConfigFile, load, save
-
Constructor Details
-
PersistentServiceProviderConsumerStore
public PersistentServiceProviderConsumerStore()
-
-
Method Details
-
add
Description copied from interface:ServiceProviderConsumerStoreAdd the consumer to the store.- Specified by:
addin interfaceServiceProviderConsumerStore- Parameters:
consumer- theconsumerto be added, cannot be null
-
get
Description copied from interface:ServiceProviderConsumerStoreRetrieve aconsumerfrom the store whosekeyattribute is equal to thekeyparameter, oremptyif such aconsumerdoesn't exist- Specified by:
getin interfaceServiceProviderConsumerStore- Parameters:
key- theconsumer key- Returns:
Consumerwhosekeyis equal to the givenkey, oremptyif such aconsumerdoesn't exist
-
getAll
Description copied from interface:ServiceProviderConsumerStoreRetrieve all theconsumersfrom the store.- Specified by:
getAllin interfaceServiceProviderConsumerStore- Returns:
- all the
consumersfrom the store
-
delete
Description copied from interface:ServiceProviderConsumerStoreDeletes a consumer whosekeyis equal to the givenkey- Specified by:
deletein interfaceServiceProviderConsumerStore- Parameters:
key- thekeyof theconsumerto be deleted
-
update
Description copied from interface:ServiceProviderConsumerStoreUpdates an existing consumer.- Specified by:
updatein interfaceServiceProviderConsumerStore- Parameters:
consumer- the consumer to update
-