public class VORS extends Object implements SiteCatalog
Modifier and Type | Field and Description |
---|---|
static String |
DEFAULT_VORS_HOST
The default VORS mVORSHost.
|
static String |
DEFAULT_VORS_PORT
The default VORS mVORSPort.
|
private String |
mGRID
The Grid for which information is required.
|
private LogManager |
mLogger
The handle to the log manager.
|
private SiteStore |
mSiteStore
The SiteStore object where information about the sites is stored.
|
private String |
mVO
The VO to which the user belongs to.
|
private Map<String,VORSVOInfo> |
mVOInfo |
private String |
mVORSHost
The mVORSHost where VORS is running.
|
private String |
mVORSPort
The VORS mVORSPort.
|
c_prefix, VERSION
DB_ALL_PREFIX
Constructor and Description |
---|
VORS()
The default constructor.
|
Modifier and Type | Method and Description |
---|---|
void |
close()
Explicitely free resources before the garbage collection hits.
|
boolean |
connect(Properties props)
Establishes a link between the implementation and the thing the
implementation is build upon.
|
int |
insert(SiteCatalogEntry entry)
Inserts a new mapping into the Site catalog.
|
boolean |
isClosed()
Predicate to check, if the connection with the catalog's
implementation is still active.
|
Set<String> |
list()
Lists the site handles for all the sites in the Site Catalog.
|
int |
load(List<String> sites)
Loads up the Site Catalog implementation with the sites whose
site handles are specified.
|
SiteCatalogEntry |
lookup(String handle)
Retrieves the
SiteCatalogEntry for a site. |
int |
remove(String handle)
Removes a site catalog entry matching the the handle.
|
public static final String DEFAULT_VORS_HOST
public static final String DEFAULT_VORS_PORT
private SiteStore mSiteStore
private Map<String,VORSVOInfo> mVOInfo
private String mVORSHost
private String mVORSPort
private String mVO
private String mGRID
private LogManager mLogger
public int insert(SiteCatalogEntry entry) throws SiteCatalogException
SiteCatalog
insert
in interface SiteCatalog
entry
- the SiteCatalogEntry
object that describes
a site.SiteCatalogException
- in case of error.public Set<String> list() throws SiteCatalogException
SiteCatalog
list
in interface SiteCatalog
SiteCatalogException
- in case of error.public int load(List<String> sites) throws SiteCatalogException
SiteCatalog
load
in interface SiteCatalog
sites
- the list of sites to be loaded.SiteCatalogException
- in case of error.public SiteCatalogEntry lookup(String handle) throws SiteCatalogException
SiteCatalog
SiteCatalogEntry
for a site.lookup
in interface SiteCatalog
handle
- the site handle / identifier.null
if no match is found.SiteCatalogException
- in case of error.public int remove(String handle) throws SiteCatalogException
SiteCatalog
remove
in interface SiteCatalog
handle
- the site handle / identifier.SiteCatalogException
- in case of error.public void close()
Catalog
public boolean connect(Properties props)
Catalog
FIXME: The cause for failure is lost without exceptions.
public boolean isClosed()
Catalog
close()
.isClosed
in interface Catalog
Catalog.close()
Copyright © 2011 The University of Southern California. All Rights Reserved.