|
Enterprise Information Portal APIs |
||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object | +--com.ibm.gcs.component.config.Config
This represents the GCS configuration, with two sections:
Globals
and an array of Group
s.
It can be constructed directly from an XML config file.
It is currently read-only for thread safety.
Globals
,
Group
Constructor Summary | |
Config(java.lang.String configFileName)
(constructor) loads the config from an XML file |
|
Config(java.lang.String name,
java.io.InputStream is)
(constructor) loads the config from an input stream. |
|
Config(java.lang.String configFileName,
java.util.List seeds,
java.util.List includePatterns)
(constructor) loads the config from an XML file, and adds specified seeds and include patterns |
Method Summary | |
void |
addIncludePattern(java.lang.String pattern)
adds an include pattern to the first CrawlPattern in the
first Group of this Config |
void |
addSeed(java.lang.String seedURL)
adds a seed URL to a CrawlPattern in this Config |
Globals |
getGlobals()
|
Group |
getGroup(java.lang.String name)
|
Group[] |
getGroups()
returns an array of the group configs |
java.lang.String |
getName()
Returns the name of this configuration. |
com.ibm.gcs.parsetools.ParseTreeModel |
getParseTree()
returns the parse tree, which is the parsed XML document |
static void |
main(java.lang.String[] args)
Testing. |
Methods inherited from class java.lang.Object |
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
public Config(java.lang.String configFileName) throws ConfigException
configFileName
- name of file from which the configuration is to be readConfigException
- when there is some problem parsing the configuration filepublic Config(java.lang.String configFileName, java.util.List seeds, java.util.List includePatterns) throws ConfigException
public Config(java.lang.String name, java.io.InputStream is) throws ConfigException
is
- The XML byte stream.ConfigException
- when there is some problem parsing the configuration fileMethod Detail |
public void addSeed(java.lang.String seedURL) throws ConfigException
CrawlPattern
in this Configpublic void addIncludePattern(java.lang.String pattern) throws ConfigException
CrawlPattern
in the
first Group
of this Configpublic java.lang.String getName()
public com.ibm.gcs.parsetools.ParseTreeModel getParseTree()
public Group[] getGroups()
public Group getGroup(java.lang.String name)
public Globals getGlobals()
public static void main(java.lang.String[] args)
|
EIP Web Crawler APIs | ||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |