|
|||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||
SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
Interface for holder finder mechanism. Used for finding suitable holders for document sources, and for registering new holder factories.
Given a document source, the finder will attempt to locate a holder most suitable for retrieving, caching and otherwise presenting that source. The finder will query any number of registered holder factories, until a factory capable of retrieving the source document will create and return a document holder.
Precedence is given to the last registered factory, so application defined factories will override the default implementation factories. The implementation will likely offer holder factories for network and file system sources. Some factories may implement mapping from public identifiers or remapping of URIs.
Source
,
Holder
,
HolderFactory
,
XCatalog
Method Summary | |
Holder |
findHolder(Source source)
Finds and returns an holder for the url. |
Holder |
findHolder(Source source,
boolean refresh)
Finds and returns an holder for the url. |
void |
registerFactory(HolderFactory factory)
Registers a new holder factory which is capable of producing holders for specific protocols or storage locations. |
void |
useCatalog(java.lang.String uri)
Use the specified XCatalog document as a catalog for mapping public identifiers to system identifiers and for remapping system identifiers. |
Method Detail |
public void useCatalog(java.lang.String uri)
uri
- The XCatalog document URIpublic void registerFactory(HolderFactory factory)
factory
- The factory to registerpublic Holder findHolder(Source source)
This method is equivalent to calling findHolder(Source,boolean)
with refresh = false.
source
- The document sourcepublic Holder findHolder(Source source, boolean refresh)
refresh is true if the source must be reloaded and not obtain from the cache. If refresh is false, the source is only loaded it it cannot be cached, or if it has been modified since it was cached.
source
- The document sourcerefresh
- True if source must be reloaded
|
|||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||
SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |