use of org.oclc.purl.dsdl.svrl.NsPrefixInAttributeValues in project ph-schematron by phax.
the class PSXPathValidationHandlerSVRL method onStart.
@Override
public void onStart(@Nonnull final PSSchema aSchema, @Nullable final PSPhase aActivePhase, @Nullable final String sBaseURI) throws SchematronValidationException {
final SchematronOutputType aSchematronOutput = new SchematronOutputType();
if (aActivePhase != null)
aSchematronOutput.setPhase(aActivePhase.getID());
aSchematronOutput.setSchemaVersion(aSchema.getSchemaVersion());
aSchematronOutput.setTitle(_getTitleAsString(aSchema.getTitle()));
// Add namespace prefixes
for (final Map.Entry<String, String> aEntry : aSchema.getAsNamespaceContext().getPrefixToNamespaceURIMap().entrySet()) {
final NsPrefixInAttributeValues aNsPrefix = new NsPrefixInAttributeValues();
aNsPrefix.setPrefix(aEntry.getKey());
aNsPrefix.setUri(aEntry.getValue());
aSchematronOutput.getNsPrefixInAttributeValues().add(aNsPrefix);
}
m_aSchematronOutput = aSchematronOutput;
m_aSchema = aSchema;
m_sBaseURI = sBaseURI;
}
Aggregations