bioformats
5.1.0
|
Xerces entity resolver. More...
#include <ome/common/xml/EntityResolver.h>
Classes | |
class | AutoRegisterCatalog |
Automatically register and unregister an XML catalog with the entity resolver. More... | |
class | AutoRegisterEntity |
Automatically register and unregister an entity with the entity resolver. More... | |
class | RegisterCatalog |
Register an XML catalog with the entity resolver. More... | |
class | RegisterEntity |
Register an entity with the entity resolver. More... | |
Public Member Functions | |
EntityResolver () | |
Constructor. | |
~EntityResolver () | |
Destructor. | |
xercesc::InputSource * | resolveEntity (xercesc::XMLResourceIdentifier *resource) |
Resolve an entity. More... | |
Private Types | |
typedef std::pair< boost::filesystem::path, std::string > | entity_cache |
Cached entity (path and content). | |
typedef std::map< std::string, entity_cache > | entity_map_type |
Entity mapping type. | |
Private Member Functions | |
xercesc::InputSource * | getSource (const std::string &resource) |
Get input source from file. More... | |
Static Private Member Functions | |
static entity_map_type & | entities () |
Get entity mappings. More... | |
Friends | |
class | RegisterEntity |
class | RegisterCatalog |
Xerces entity resolver.
This resolver allows replacement of URLs with local files or in-memory copies of XML schemas. This permits efficient validation without network access for commonly-used schemas.
|
staticprivate |
Get entity mappings.
Referenced by ome::common::xml::EntityResolver::AutoRegisterEntity::AutoRegisterEntity(), getSource(), and ome::common::xml::EntityResolver::AutoRegisterEntity::~AutoRegisterEntity().
|
private |
Get input source from file.
Open and read the contents of the file, then return this as an InputSource. Use cached content if possible.
resource | the resource to resolve. |
References entities().
Referenced by resolveEntity().
xercesc::InputSource * ome::common::xml::EntityResolver::resolveEntity | ( | xercesc::XMLResourceIdentifier * | resource | ) |
Resolve an entity.
resource | the resource to resolve. |
References getSource().