public class StandardCatalogBuilder extends java.lang.Object implements CatalogBuilder
Constructor and Description |
---|
StandardCatalogBuilder(java.lang.String collectionPath,
java.lang.String collectionName,
CrawlableDataset collectionCrDs,
CrawlableDatasetFilter filter,
InvService service,
java.lang.String collectionId,
CrawlableDatasetLabeler identifier,
CrawlableDatasetLabeler namer,
boolean doAddDatasetSize,
CrawlableDatasetSorter sorter,
java.util.Map proxyDatasetHandlers,
java.util.List childEnhancerList,
InvDatasetImpl topLevelMetadataContainer,
CatalogRefExpander catalogRefExpander) |
Modifier and Type | Method and Description |
---|---|
InvCatalogImpl |
generateCatalog(CrawlableDataset catalogCrDs)
Return an InvCatalog for the level in the collection hierarchy specified by catalogPath.
|
org.jdom2.Document |
generateCatalogAsDocument(CrawlableDataset catalogCrDs)
Return a JDOM Document representation of the catalog for the level in
the collection hierarchy specified by catalogPath.
|
java.lang.String |
generateCatalogAsString(CrawlableDataset catalogCrDs)
Return a String containing the XML representation of the catalog for the
level in the collection hierarchy specified by catalogPath.
|
InvCatalogImpl |
generateProxyDsResolverCatalog(CrawlableDataset catalogCrDs,
ProxyDatasetHandler pdh)
Generate the catalog for a resolver request of the given ProxyDatasetHandler.
|
CrawlableDataset |
requestCrawlableDataset(java.lang.String path)
Return the CrawlableDataset for the given path, null if this CatalogBuilder
does not allow the requested CrawlableDataset.
|
public StandardCatalogBuilder(java.lang.String collectionPath, java.lang.String collectionName, CrawlableDataset collectionCrDs, CrawlableDatasetFilter filter, InvService service, java.lang.String collectionId, CrawlableDatasetLabeler identifier, CrawlableDatasetLabeler namer, boolean doAddDatasetSize, CrawlableDatasetSorter sorter, java.util.Map proxyDatasetHandlers, java.util.List childEnhancerList, InvDatasetImpl topLevelMetadataContainer, CatalogRefExpander catalogRefExpander)
public CrawlableDataset requestCrawlableDataset(java.lang.String path) throws java.io.IOException
CatalogBuilder
This method can handle requests for regular datasets and proxy datasets.
requestCrawlableDataset
in interface CatalogBuilder
path
- the path of the requested CrawlableDatasetjava.io.IOException
- if an I/O error occurs while locating the children datasets.public InvCatalogImpl generateCatalog(CrawlableDataset catalogCrDs) throws java.io.IOException
CatalogBuilder
generateCatalog
in interface CatalogBuilder
catalogCrDs
- the location in the collection at which to generate a catalogjava.io.IOException
- if problems accessing the dataset collection.public InvCatalogImpl generateProxyDsResolverCatalog(CrawlableDataset catalogCrDs, ProxyDatasetHandler pdh) throws java.io.IOException
CatalogBuilder
generateProxyDsResolverCatalog
in interface CatalogBuilder
catalogCrDs
- the location in the collection at which to generate a catalogpdh
- the ProxyDatasetHandler corresponding to the resolver request.java.io.IOException
public org.jdom2.Document generateCatalogAsDocument(CrawlableDataset catalogCrDs) throws java.io.IOException
CatalogBuilder
generateCatalogAsDocument
in interface CatalogBuilder
catalogCrDs
- the location in the collection at which to generate a catalogjava.io.IOException
- if problems accessing the dataset collection.public java.lang.String generateCatalogAsString(CrawlableDataset catalogCrDs) throws java.io.IOException
CatalogBuilder
generateCatalogAsString
in interface CatalogBuilder
catalogCrDs
- the location in the collection at which to generate a catalogjava.io.IOException
- if problems accessing the dataset collection.