@Immutable public class PSReader extends Object
Constructor and Description |
---|
PSReader(com.helger.commons.io.resource.IReadableResource aResource)
Constructor without an error handler
|
PSReader(com.helger.commons.io.resource.IReadableResource aResource,
IPSErrorHandler aErrorHandler)
Constructor with an error handler
|
PSReader(com.helger.commons.io.resource.IReadableResource aResource,
IPSErrorHandler aErrorHandler,
EntityResolver aEntityResolver)
Constructor with an error handler
|
Modifier and Type | Method and Description |
---|---|
IPSErrorHandler |
getErrorHandler() |
com.helger.commons.io.resource.IReadableResource |
getResource() |
PSActive |
readActiveFromXML(com.helger.xml.microdom.IMicroElement eActive)
Read an <active> element
|
PSAssertReport |
readAssertReportFromXML(com.helger.xml.microdom.IMicroElement eAssertReport)
Read an <assert> or a <report> element
|
PSDiagnostic |
readDiagnosticFromXML(com.helger.xml.microdom.IMicroElement eDiagnostic)
Read a <diagnostic> element
|
PSDiagnostics |
readDiagnosticsFromXML(com.helger.xml.microdom.IMicroElement eDiagnostics)
Read a <diagnostics> element
|
PSDir |
readDirFromXML(com.helger.xml.microdom.IMicroElement eDir)
Read a <dir> element
|
PSEmph |
readEmphFromXML(com.helger.xml.microdom.IMicroElement eEmph)
Read an <emph> element
|
PSExtends |
readExtendsFromXML(com.helger.xml.microdom.IMicroElement eExtends)
Read an <extends> element
|
PSInclude |
readIncludeFromXML(com.helger.xml.microdom.IMicroElement eInclude)
Read an <include> element
|
PSLet |
readLetFromXML(com.helger.xml.microdom.IMicroElement eLet)
Read a <let> element
|
PSName |
readNameFromXML(com.helger.xml.microdom.IMicroElement eName)
Read a <name> element
|
PSNS |
readNSFromXML(com.helger.xml.microdom.IMicroElement eNS)
Read a <ns> element
|
PSParam |
readParamFromXML(com.helger.xml.microdom.IMicroElement eParam)
Read a <param> element
|
PSPattern |
readPatternFromXML(com.helger.xml.microdom.IMicroElement ePattern)
Read a <pattern> element
|
PSP |
readPFromXML(com.helger.xml.microdom.IMicroElement eP)
Read a <p> element
|
PSPhase |
readPhaseFromXML(com.helger.xml.microdom.IMicroElement ePhase)
Read a <phase> element
|
PSRule |
readRuleFromXML(com.helger.xml.microdom.IMicroElement eRule)
Read a <rule> element
|
PSSchema |
readSchema()
Read the schema from the resource supplied in the constructor.
|
PSSchema |
readSchemaFromXML(com.helger.xml.microdom.IMicroElement eSchema)
Parse the Schematron into a pure Java object.
|
PSSpan |
readSpanFromXML(com.helger.xml.microdom.IMicroElement eSpan)
Read a <span> element
|
PSTitle |
readTitleFromXML(com.helger.xml.microdom.IMicroElement eTitle)
Read a <title> element
|
PSValueOf |
readValueOfFromXML(com.helger.xml.microdom.IMicroElement eValueOf)
Read a <value-of> element
|
String |
toString() |
public PSReader(@Nonnull com.helger.commons.io.resource.IReadableResource aResource)
aResource
- The resource to read the Schematron from. May not be
null
.public PSReader(@Nonnull com.helger.commons.io.resource.IReadableResource aResource, @Nullable IPSErrorHandler aErrorHandler)
aResource
- The resource to read the Schematron from. May not be
null
.aErrorHandler
- The error handler to use. May be null
. If the error
handler is null
a LoggingPSErrorHandler
is
automatically created and used.public PSReader(@Nonnull com.helger.commons.io.resource.IReadableResource aResource, @Nullable IPSErrorHandler aErrorHandler, @Nullable EntityResolver aEntityResolver)
aResource
- The resource to read the Schematron from. May not be
null
.aErrorHandler
- The error handler to use. May be null
. If the error
handler is null
a LoggingPSErrorHandler
is
automatically created and used.aEntityResolver
- The XML entity resolver to be used. May be null
.@Nonnull public com.helger.commons.io.resource.IReadableResource getResource()
null
.@Nonnull public IPSErrorHandler getErrorHandler()
LoggingPSErrorHandler
is automatically
used.@Nonnull public PSActive readActiveFromXML(@Nonnull com.helger.xml.microdom.IMicroElement eActive)
eActive
- The source micro element. Never null
.null
.@Nonnull public PSAssertReport readAssertReportFromXML(@Nonnull com.helger.xml.microdom.IMicroElement eAssertReport)
eAssertReport
- The source micro element. Never null
.null
.@Nonnull public PSDiagnostic readDiagnosticFromXML(@Nonnull com.helger.xml.microdom.IMicroElement eDiagnostic)
eDiagnostic
- The source micro element. Never null
.null
.@Nonnull public PSDiagnostics readDiagnosticsFromXML(@Nonnull com.helger.xml.microdom.IMicroElement eDiagnostics)
eDiagnostics
- The source micro element. Never null
.null
.@Nonnull public PSDir readDirFromXML(@Nonnull com.helger.xml.microdom.IMicroElement eDir)
eDir
- The source micro element. Never null
.null
.@Nonnull public PSEmph readEmphFromXML(@Nonnull com.helger.xml.microdom.IMicroElement eEmph)
eEmph
- The source micro element. Never null
.null
.@Nonnull public PSExtends readExtendsFromXML(@Nonnull com.helger.xml.microdom.IMicroElement eExtends)
eExtends
- The source micro element. Never null
.null
.@Nonnull public PSInclude readIncludeFromXML(@Nonnull com.helger.xml.microdom.IMicroElement eInclude)
eInclude
- The source micro element. Never null
.null
.@Nonnull public PSLet readLetFromXML(@Nonnull com.helger.xml.microdom.IMicroElement eLet)
eLet
- The source micro element. Never null
.null
.@Nonnull public PSName readNameFromXML(@Nonnull com.helger.xml.microdom.IMicroElement eName)
eName
- The source micro element. Never null
.null
.@Nonnull public PSNS readNSFromXML(@Nonnull com.helger.xml.microdom.IMicroElement eNS)
eNS
- The source micro element. Never null
.null
.@Nonnull public PSP readPFromXML(@Nonnull com.helger.xml.microdom.IMicroElement eP)
eP
- The source micro element. Never null
.null
.@Nonnull public PSParam readParamFromXML(@Nonnull com.helger.xml.microdom.IMicroElement eParam)
eParam
- The source micro element. Never null
.null
.@Nonnull public PSPattern readPatternFromXML(@Nonnull com.helger.xml.microdom.IMicroElement ePattern)
ePattern
- The source micro element. Never null
.null
.@Nonnull public PSPhase readPhaseFromXML(@Nonnull com.helger.xml.microdom.IMicroElement ePhase)
ePhase
- The source micro element. Never null
.null
.@Nonnull public PSRule readRuleFromXML(@Nonnull com.helger.xml.microdom.IMicroElement eRule)
eRule
- The source micro element. Never null
.null
.@Nonnull public PSSchema readSchemaFromXML(@Nonnull com.helger.xml.microdom.IMicroElement eSchema) throws SchematronReadException
eSchema
- The XML element to use. May not be null
.PSSchema
object or null
in case of
null
document or a fatal error.SchematronReadException
- If reading fails@Nonnull public PSSpan readSpanFromXML(@Nonnull com.helger.xml.microdom.IMicroElement eSpan)
eSpan
- The source micro element. Never null
.null
.@Nonnull public PSTitle readTitleFromXML(@Nonnull com.helger.xml.microdom.IMicroElement eTitle)
eTitle
- The source micro element. Never null
.null
.@Nonnull public PSValueOf readValueOfFromXML(@Nonnull com.helger.xml.microdom.IMicroElement eValueOf)
eValueOf
- The source micro element. Never null
.null
.@Nonnull public PSSchema readSchema() throws SchematronReadException
readSchemaFromXML(IMicroElement)
is
called.PSSchema
.SchematronReadException
- If reading failsCopyright © 2014–2017 Philip Helger. All rights reserved.