public class MYOSGSiteCatalogParser extends Parser
| Modifier and Type | Field and Description |
|---|---|
(package private) Stack<AbstractSiteCatalogResource> |
elementStack |
static String |
ENV_TAG |
private int |
mDepth |
private boolean |
mLoadAll
A boolean indicating whether to load all sites.
|
private LogManager |
mLogger
The handle to the log manager.
|
private Set<String> |
mSites
The set of sites that need to be parsed.
|
static String |
RESOURCE_GROUP_TAG |
static String |
RESOURCE_TAG |
static String |
SERVICE_TAG |
(package private) List<AbstractSiteCatalogResource> |
siteList |
static String |
VO_OWNERSHIP_TAG |
DEFAULT_PARSER_NAME, mAdjFName, mLocator, mLogMsg, mParser, mProps, mTextContent, mTextString| Constructor and Description |
|---|
MYOSGSiteCatalogParser()
The default Constructor.
|
MYOSGSiteCatalogParser(List<String> sites) |
MYOSGSiteCatalogParser(PegasusProperties properties,
List<String> sites) |
| Modifier and Type | Method and Description |
|---|---|
void |
endDocument()
This is called automatically when the end of the XML file is reached.
|
void |
endElement(String uri,
String localName,
String name)
The parser is at the end of an element.
|
int |
getNumberOfSites()
Returns the number of sites parsed
|
String |
getSchemaLocation()
Helps the load database to locate the XML schema, if available.
|
String |
getSchemaNamespace()
Returns the XML schema namespace that a document being parsed conforms
to.
|
List |
getSites()
Returns the site's list
|
private boolean |
isStackedElement(String name) |
private boolean |
loadSite(AbstractSiteCatalogResource site)
Whether to laod a site or not in the
SiteStore |
void |
startElement(String uri,
String local,
String name,
Attributes attrs)
This method defines the action to take when the parser begins to parse
an element.
|
void |
startParser(String file)
The main method that starts the parsing.
|
characters, ignoreWhitespace, ignoreWhitespace, setDocumentLocator, setParserFeature, setSchemaLocations, testForFileendPrefixMapping, error, fatalError, ignorableWhitespace, notationDecl, processingInstruction, resolveEntity, skippedEntity, startDocument, startPrefixMapping, unparsedEntityDecl, warningpublic static final String RESOURCE_GROUP_TAG
public static final String SERVICE_TAG
public static final String RESOURCE_TAG
public static final String ENV_TAG
public static final String VO_OWNERSHIP_TAG
private int mDepth
Stack<AbstractSiteCatalogResource> elementStack
List<AbstractSiteCatalogResource> siteList
private LogManager mLogger
private boolean mLoadAll
public MYOSGSiteCatalogParser()
public MYOSGSiteCatalogParser(PegasusProperties properties, List<String> sites)
public void endDocument()
ParserendDocument in interface ContentHandlerendDocument in class Parserpublic void endElement(String uri, String localName, String name) throws SAXException
endElement in interface ContentHandlerendElement in class Parseruri - is the URI of the namespace for the elementlocalName - is the element name without namespacename - is the element name as it appears in the docmentSAXExceptionprivate boolean isStackedElement(String name)
private boolean loadSite(AbstractSiteCatalogResource site)
SiteStoresite - the SiteCatalogEntry object.public String getSchemaNamespace()
getSchemaNamespace in class Parserpublic String getSchemaLocation()
ParsergetSchemaLocation in class Parserpublic void startElement(String uri, String local, String name, Attributes attrs) throws SAXException
startElement in interface ContentHandlerstartElement in class Parseruri - is the URI of the namespace for the elementlocal - is the element name without namespacename - is the element name as it appears in the docmentattrs - has the names and values of all the attributesSAXExceptionpublic void startParser(String file)
startParser in class Parserfile - the XML file to be parsed.public List getSites()
public int getNumberOfSites()
Copyright © 2011 The University of Southern California. All Rights Reserved.