|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object org.w3c.mwi.mobileok.basic.PreprocessorResults
public final class PreprocessorResults
Encapsulates the moki representation of a primary Web resource and of all the Web resources it might import, embed, or link to.
The moki representation of a resource follows the moki schema.
The class in itself mostly defines getters and setters to internal fields. These fields could have different meanings depending on the use of the class. The class methods descriptions explain how these fields are used within the mobileOK Checker.
Preprocessor
Field Summary | |
---|---|
private org.w3c.dom.Document |
mokiDocument
The moki representation of this instance. |
private java.util.List<Resource> |
resources
Pointer to the list of resources that are at the source of the moki representation. |
private org.w3c.dom.Document |
saxonMokiDocument
The moki representation of this instance that takes
advantage of a few features of Saxon (e.g. |
Constructor Summary | |
---|---|
PreprocessorResults(java.util.List<Resource> resources)
Creates a PreprocessorResults instance associated with the given list of resources. |
Method Summary | |
---|---|
private org.w3c.dom.Document |
buildMokiDocument()
Creates the moki representation of the resource using
all the information contained in this instance. |
private java.lang.String |
getLocalHostIP()
Static helper method that returns the IP address of localhost. |
org.w3c.dom.Document |
getMokiDocument()
Returns the moki representation of the resource. |
org.w3c.dom.Document |
getSaxonMokiDocument()
Returns the moki representation of the resource built
specifically to take advantage of features of Saxon, and typically the
possibility to keep line numbers even when the document is represented
as a DOM tree. |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
---|
private final java.util.List<Resource> resources
private org.w3c.dom.Document mokiDocument
moki
representation of this instance.
private org.w3c.dom.Document saxonMokiDocument
moki
representation of this instance that takes
advantage of a few features of Saxon (e.g. line numbering).
Constructor Detail |
---|
public PreprocessorResults(java.util.List<Resource> resources)
The list should contain one resource identified as
ResourceContext.Primary
. If it contains more than one primary
resources, the first one in the list will be used as the primary
resource for the moki document.
resources
- list of resources to represent in the moki documentMethod Detail |
---|
public org.w3c.dom.Document getMokiDocument() throws TestException
moki
representation of the resource.
moki
DOM document that represents the resource.
TestException
- an unexpected error occurred while building the document.public org.w3c.dom.Document getSaxonMokiDocument() throws TestException
moki
representation of the resource built
specifically to take advantage of features of Saxon, and typically the
possibility to keep line numbers even when the document is represented
as a DOM tree.
moki
for Saxon representation of the resource
TestException
- an unexpected error occurred while building the document.private java.lang.String getLocalHostIP()
127.0.0.1
.private org.w3c.dom.Document buildMokiDocument() throws TestException
moki
representation of the resource using
all the information contained in this instance.
moki
DOM document representing the resource.
TestException
- an unexpected error occurred while building the document.
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |