public abstract class Diff extends Object
Modifier and Type | Field and Description |
---|---|
static boolean |
ALLOW_DIFFERENT_IDS
Are mappings of nodes with different ids allowed?
At the first glimpse that might sound stupid, but ids are generally arbitrary and say nothing valuable about the entities.
|
static boolean |
CARE_ABOUT_NAMES
Do we care about names?
Should we treat names differently? They often provide more information than other attributes.
|
protected SimpleConnectionManager |
connections
The connections.
|
static boolean |
STRICTER_NAMES
Should we handle names very strictly?
Go for this option if you're sure that you're names are very similar.
|
protected de.unirostock.sems.xmlutils.ds.TreeDocument |
treeA
The tree corresponding to the former version.
|
protected de.unirostock.sems.xmlutils.ds.TreeDocument |
treeB
The tree corresponding to the later version.
|
Constructor and Description |
---|
Diff(File fileA,
File fileB)
Instantiates a new diff object in order to compare two documents stored in
files fileA and fileB.
|
Diff(File fileA,
File fileB,
DiffAnnotator diffAnnotator)
Instantiates a new diff object in order to compare two documents stored in
files fileA and fileB.
|
Diff(String docA,
String docB)
Instantiates a new diff object in order to compare two documents stored in
strings docA and docB.
|
Diff(String docA,
String docB,
DiffAnnotator diffAnnotator)
Instantiates a new diff object in order to compare two documents stored in
strings docA and docB.
|
Diff(de.unirostock.sems.xmlutils.ds.TreeDocument treeA,
de.unirostock.sems.xmlutils.ds.TreeDocument treeB)
Instantiates a new diff object in order to compare two tree documents.
|
Diff(de.unirostock.sems.xmlutils.ds.TreeDocument treeA,
de.unirostock.sems.xmlutils.ds.TreeDocument treeB,
DiffAnnotator diffAnnotator)
Instantiates a new diff object in order to compare two tree documents.
|
Modifier and Type | Method and Description |
---|---|
String |
getCRNDotGraph()
Deprecated.
As of 1.3.3 replaced by
getReactionsDotGraph() |
Object |
getCRNGraph(GraphTranslator gt)
Deprecated.
As of 1.3.3 replaced by
getReactionsGraph(de.unirostock.sems.bives.ds.graph.GraphTranslator) |
String |
getCRNGraphML()
Deprecated.
As of 1.3.3 replaced by
getReactionsGraphML() |
String |
getCRNJsonGraph()
Deprecated.
As of 1.3.3 replaced by
getReactionsJsonGraph() |
String |
getDiff()
Gets the diff as a string, encoded in XML.
|
String |
getDiff(boolean inclAnnotations)
Gets the differences encoded in an XML string
|
abstract String |
getHierarchyDotGraph()
Returns the component's hierarchy graph encoded in DOT language.
|
abstract Object |
getHierarchyGraph(GraphTranslator gt)
Returns the component's hierarchy graph providing an own graph translator.
|
abstract String |
getHierarchyGraphML()
Returns the component's hierarchy graph encoded in GraphML.
|
abstract String |
getHierarchyJsonGraph()
Returns the component's hierarchy graph encoded in JSON.
|
abstract String |
getHTMLReport()
Returns the report encoded in HTML.
|
abstract String |
getMarkDownReport()
Returns the report encoded MarkDown.
|
Patch |
getPatch()
Gets the patch object.
|
abstract String |
getReactionsDotGraph()
Returns the graph of the reaction network encoded in DOT language.
|
abstract Object |
getReactionsGraph(GraphTranslator gt)
Returns the graph of the reaction network providing an own graph
translator.
|
abstract String |
getReactionsGraphML()
Returns the graph of the reaction network encoded in GraphML.
|
abstract String |
getReactionsJsonGraph()
Returns the graph of the reaction network encoded in JSON.
|
abstract String |
getReactionsSbgnJsonGraph()
Returns the graph of the reaction network encoded in an SBGN-JSON format.
|
abstract String |
getReport(Typesetting ts)
Returns the report providing an on markup processor.
|
abstract String |
getReStructuredTextReport()
Returns the report encoded in ReStructured text.
|
boolean |
mapTrees()
Map both trees.
|
abstract boolean |
mapTrees(boolean allowDifferentIds,
boolean careAboutNames,
boolean stricterNames)
Map both trees.
|
public static final boolean ALLOW_DIFFERENT_IDS
<species id="s1" name="glucose" initial_concentration="0.1" compartment="cell" initialAmount="1" hasOnlySubstanceUnits="true" boundaryCondition="true" /> <species id="species1" name="glucose" initial_concentration="0.1" compartment="cell" initialAmount="1" hasOnlySubstanceUnits="true" boundaryCondition="true" />The id attribute might just be assigned by two different tools, everything else is the same. Should we map these entities? By default this is
true
.DocumentNode.getAttributeDistance(DocumentNode, boolean, boolean, boolean)
,
Constant Field Valuespublic static final boolean CARE_ABOUT_NAMES
DocumentNode.getAttributeDistance(DocumentNode, boolean, boolean, boolean)
,
Constant Field Valuespublic static final boolean STRICTER_NAMES
DocumentNode.getAttributeDistance(DocumentNode, boolean, boolean, boolean)
,
Constant Field Valuesprotected de.unirostock.sems.xmlutils.ds.TreeDocument treeA
protected de.unirostock.sems.xmlutils.ds.TreeDocument treeB
protected SimpleConnectionManager connections
public Diff(File fileA, File fileB) throws de.unirostock.sems.xmlutils.exception.XmlDocumentParseException, IOException, org.jdom2.JDOMException
fileA
- the file containing the former versionfileB
- the file containing the later versionde.unirostock.sems.xmlutils.exception.XmlDocumentParseException
- the xml document parse exceptionIOException
- Signals that an I/O exception has occurred.org.jdom2.JDOMException
- the jDOM exceptionpublic Diff(String docA, String docB) throws de.unirostock.sems.xmlutils.exception.XmlDocumentParseException, IOException, org.jdom2.JDOMException
docA
- the former versiondocB
- the later versionde.unirostock.sems.xmlutils.exception.XmlDocumentParseException
- the xml document parse exceptionIOException
- Signals that an I/O exception has occurred.org.jdom2.JDOMException
- the jDOM exceptionpublic Diff(de.unirostock.sems.xmlutils.ds.TreeDocument treeA, de.unirostock.sems.xmlutils.ds.TreeDocument treeB)
treeA
- the former version of the treetreeB
- the later version of the treepublic Diff(File fileA, File fileB, DiffAnnotator diffAnnotator) throws de.unirostock.sems.xmlutils.exception.XmlDocumentParseException, IOException, org.jdom2.JDOMException
fileA
- the file containing the former versionfileB
- the file containing the later versiondiffAnnotator
- the annotator for identified changesde.unirostock.sems.xmlutils.exception.XmlDocumentParseException
- the xml document parse exceptionIOException
- Signals that an I/O exception has occurred.org.jdom2.JDOMException
- the jDOM exceptionpublic Diff(String docA, String docB, DiffAnnotator diffAnnotator) throws de.unirostock.sems.xmlutils.exception.XmlDocumentParseException, IOException, org.jdom2.JDOMException
docA
- the former versiondocB
- the later versiondiffAnnotator
- the annotator for identified changesde.unirostock.sems.xmlutils.exception.XmlDocumentParseException
- the xml document parse exceptionIOException
- Signals that an I/O exception has occurred.org.jdom2.JDOMException
- the jDOM exceptionpublic Diff(de.unirostock.sems.xmlutils.ds.TreeDocument treeA, de.unirostock.sems.xmlutils.ds.TreeDocument treeB, DiffAnnotator diffAnnotator)
treeA
- the former version of the treetreeB
- the later version of the treediffAnnotator
- the annotator for identified changespublic String getDiff()
public String getDiff(boolean inclAnnotations)
inclAnnotations
- include annotations in the XML patchpublic Patch getPatch()
public abstract boolean mapTrees(boolean allowDifferentIds, boolean careAboutNames, boolean stricterNames) throws Exception
ALLOW_DIFFERENT_IDS
, CARE_ABOUT_NAMES
, and STRICTER_NAMES
.allowDifferentIds
- are mapped entities allowed to have different ids?careAboutNames
- should we care about names?stricterNames
- should we handle names very strictly?Exception
- the exceptionpublic boolean mapTrees() throws Exception
DocumentNode.getAttributeDistance(DocumentNode, boolean, boolean, boolean)
.Exception
- the exception@Deprecated public Object getCRNGraph(GraphTranslator gt) throws Exception
getReactionsGraph(de.unirostock.sems.bives.ds.graph.GraphTranslator)
gt
- the graph translatorException
- the exceptionpublic abstract Object getReactionsGraph(GraphTranslator gt) throws Exception
gt
- the graph translatorException
- the exceptionpublic abstract Object getHierarchyGraph(GraphTranslator gt) throws Exception
gt
- the graph translatorException
- the exception@Deprecated public String getCRNGraphML() throws Exception
getReactionsGraphML()
Exception
- the exceptionpublic abstract String getReactionsGraphML() throws Exception
Exception
- the exceptionpublic abstract String getHierarchyGraphML() throws Exception
Exception
- the exception@Deprecated public String getCRNDotGraph() throws Exception
getReactionsDotGraph()
Exception
- the exceptionpublic abstract String getReactionsDotGraph() throws Exception
Exception
- the exceptionpublic abstract String getHierarchyDotGraph() throws Exception
Exception
- the exception@Deprecated public String getCRNJsonGraph() throws Exception
getReactionsJsonGraph()
Exception
- the exceptionpublic abstract String getReactionsJsonGraph() throws Exception
Exception
- the exceptionpublic abstract String getHierarchyJsonGraph() throws Exception
Exception
- the exceptionpublic abstract String getReactionsSbgnJsonGraph() throws Exception
Exception
- the exceptionpublic abstract String getReport(Typesetting ts) throws Exception
ts
- the tsException
- the exceptionpublic abstract String getHTMLReport() throws Exception
Exception
- the exceptionpublic abstract String getMarkDownReport() throws Exception
Exception
- the exceptionCopyright © 2019 SEMS project @ University of Rostock. All rights reserved.