|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectuk.ac.starlink.vo.RegistryProtocol
public abstract class RegistryProtocol
Defines the details of a registry access protocol.
Field Summary | |
---|---|
static RegistryProtocol[] |
PROTOCOLS
Known protocols. |
static RegistryProtocol |
REGTAP
Protocol instance for Relational Registry 1.0. |
static RegistryProtocol |
RI1
Protocol instance for Registry Interface 1.0. |
Constructor Summary | |
---|---|
protected |
RegistryProtocol(String shortName,
String fullName,
String[] dfltUrls)
Constructor. |
Method Summary | |
---|---|
abstract RegistryQuery |
createIdListQuery(String[] ivoids,
Capability capability,
URL regUrl)
Constructs a registry query that gets results for a list of given IVO ID strings, optionally restricted by a given capability. |
abstract RegistryQuery |
createKeywordQuery(String[] keywords,
ResourceField[] rfs,
boolean isOr,
Capability capability,
URL regUrl)
Constructs a registry query that gets results for resources with a match for one or all of a given set of keywords found in a selection of resource fields. |
abstract String[] |
discoverRegistryUrls(String regUrl0)
Searches a given registry to discover new endpoint URLs serving this registry protocol. |
String[] |
getDefaultRegistryUrls()
Returns default endpoint URLs for this protocol. |
String |
getFullName()
Returns the full name for this protocol. |
String |
getShortName()
Returns a short name for this protocol. |
abstract boolean |
hasCapability(Capability stdCap,
RegCapabilityInterface resCap)
Indicates whether a given RegCapabilityInterface object is an instance of a given capability. |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
---|
public static final RegistryProtocol RI1
public static final RegistryProtocol REGTAP
public static final RegistryProtocol[] PROTOCOLS
Constructor Detail |
---|
protected RegistryProtocol(String shortName, String fullName, String[] dfltUrls)
shortName
- short namefullName
- full namedfltUrls
- strings giving some default registry endpoints for
this access protocolMethod Detail |
---|
public String getShortName()
public String getFullName()
public String[] getDefaultRegistryUrls()
public abstract String[] discoverRegistryUrls(String regUrl0) throws IOException
regUrl0
- bootstrap registry endpoint URL
IOException
public abstract RegistryQuery createIdListQuery(String[] ivoids, Capability capability, URL regUrl)
ivoids
list, and
(c) has the given capability
If capability
is null, then restriction (c) does not apply.
If the input list of IDs is null or empty, the return value will be null.
ivoids
- ID values for the required resourcescapability
- service capability type, or nullregUrl
- endpoint URL for a registry service implementing
this protocol
public abstract RegistryQuery createKeywordQuery(String[] keywords, ResourceField[] rfs, boolean isOr, Capability capability, URL regUrl)
keywords
- single-word keywords to match independentlyrfs
- resource fields against which keywords are to matchisOr
- if false all keywords must match,
if true at least one keyword must matchcapability
- if non-null, restricts the resources to those
with that capabilityregUrl
- endpoint URL for a registry service implementing
this protocol
public abstract boolean hasCapability(Capability stdCap, RegCapabilityInterface resCap)
Really, the implementation of this ought not to be a function of the registry protocol in use. However, it's probably the case that the different registry implementations have different quirks in this respect, so take the opportunity to parameterise it by registry protocol in case that's required.
stdCap
- standard capability definitionresCap
- capability interface object representing part of
a registry resource
resCap
represents a capability
of the type stdCap
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |