|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object javax.management.Attribute org.archive.crawler.settings.Type org.archive.crawler.settings.ComplexType org.archive.crawler.settings.ModuleType org.archive.crawler.datamodel.CredentialStore
public class CredentialStore
Front door to the credential store. Come here to get at credentials.
Nested Class Summary |
---|
Nested classes/interfaces inherited from class org.archive.crawler.settings.ComplexType |
---|
ComplexType.MBeanAttributeInfoIterator |
Field Summary | |
---|---|
static java.lang.String |
ATTR_CREDENTIALS
Name of the contained credentials map type. |
static java.lang.String |
ATTR_NAME
|
Fields inherited from class org.archive.crawler.settings.ComplexType |
---|
definition, definitionMap |
Constructor Summary | |
---|---|
CredentialStore(java.lang.String name)
Constructor. |
Method Summary | |
---|---|
Credential |
create(CrawlerSettings context,
java.lang.String name,
java.lang.Class type)
Create and add to the list a credential of the passed type
giving the credential the passed name . |
protected MapType |
get(java.lang.Object context)
|
Credential |
get(java.lang.Object context,
java.lang.String name)
|
static CredentialStore |
getCredentialStore(SettingsHandler context)
Get a credential store reference. |
static java.util.List |
getCredentialTypes()
|
java.util.Iterator |
iterator(java.lang.Object context)
Get an Iterator over all the attributes in this ComplexType. |
void |
remove(CrawlerSettings context,
Credential credential)
Delete the credential name . |
void |
remove(CrawlerSettings context,
java.lang.String name)
Delete the credential name . |
java.util.Set |
subset(CrawlURI context,
java.lang.Class type)
Return set made up of all credentials of the passed type . |
java.util.Set<Credential> |
subset(CrawlURI context,
java.lang.Class type,
java.lang.String rootUri)
Return set made up of all credentials of the passed type . |
Methods inherited from class org.archive.crawler.settings.ModuleType |
---|
addElement, listUsedFiles |
Methods inherited from class org.archive.crawler.settings.Type |
---|
addConstraint, equals, getConstraints, getLegalValueType, isExpertSetting, isOverrideable, isTransient, setExpertSetting, setLegalValueType, setOverrideable, setTransient |
Methods inherited from class javax.management.Attribute |
---|
getName, hashCode |
Methods inherited from class java.lang.Object |
---|
clone, finalize, getClass, notify, notifyAll, wait, wait, wait |
Field Detail |
---|
public static final java.lang.String ATTR_NAME
public static final java.lang.String ATTR_CREDENTIALS
Constructor Detail |
---|
public CredentialStore(java.lang.String name)
name
- for this credential store.Method Detail |
---|
public static java.util.List getCredentialTypes()
public static CredentialStore getCredentialStore(SettingsHandler context)
context
- A settingshandler object.
protected MapType get(java.lang.Object context) throws javax.management.AttributeNotFoundException
context
- Pass a CrawlURI, CrawlerSettings or UURI. Used to set
context. If null, we use global context.
javax.management.AttributeNotFoundException
public java.util.Iterator iterator(java.lang.Object context)
ComplexType
iterator
in class ComplexType
context
- Pass a CrawlURI, CrawlerSettings or UURI. Used to set
context. If null, we use global context.
public Credential get(java.lang.Object context, java.lang.String name) throws javax.management.AttributeNotFoundException, javax.management.MBeanException, javax.management.ReflectionException
context
- Pass a CrawlURI, CrawlerSettings or UURI. Used to set
context. If null, we use global context.name
- Name to give the manufactured credential. Should be unique
else the add of the credential to the list of credentials will fail.
name
'd credential.
javax.management.AttributeNotFoundException
javax.management.MBeanException
javax.management.ReflectionException
public Credential create(CrawlerSettings context, java.lang.String name, java.lang.Class type) throws java.lang.IllegalArgumentException, java.lang.reflect.InvocationTargetException, javax.management.InvalidAttributeValueException, javax.management.AttributeNotFoundException
type
giving the credential the passed name
.
context
- Pass a CrawlerSettings. Used to set
context. If null, we use global context.name
- Name to give the manufactured credential. Should be unique
else the add of the credential to the list of credentials will fail.type
- Type of credentials to get.
java.lang.IllegalArgumentException
javax.management.AttributeNotFoundException
java.lang.reflect.InvocationTargetException
javax.management.InvalidAttributeValueException
public void remove(CrawlerSettings context, Credential credential) throws javax.management.AttributeNotFoundException, java.lang.IllegalArgumentException
name
.
context
- Pass a CrawlerSettings. Used to set
context. If null, we use global context.credential
- Credential to delete.
java.lang.IllegalArgumentException
javax.management.AttributeNotFoundException
public void remove(CrawlerSettings context, java.lang.String name) throws java.lang.IllegalArgumentException, javax.management.AttributeNotFoundException
name
.
context
- Pass a CrawlerSettings. Used to set
context. If null, we use global context.name
- Name of credential to delete.
java.lang.IllegalArgumentException
javax.management.AttributeNotFoundException
public java.util.Set subset(CrawlURI context, java.lang.Class type)
type
.
context
- Pass a CrawlURI or a CrawlerSettings. Used to set
context. If null, we use global context.type
- Type of the list to return. Type is some superclass of
credentials.
public java.util.Set<Credential> subset(CrawlURI context, java.lang.Class type, java.lang.String rootUri)
type
.
context
- Pass a CrawlURI or a CrawlerSettings. Used to set
context. If null, we use global context.type
- Type of the list to return. Type is some superclass of
credentials.rootUri
- RootUri to match. May be null. In this case we return
all. Currently we expect the CrawlServer name to equate to root Uri.
Its not. Currently it doesn't distingush between servers of same name
but different ports (e.g. http and https).
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |