Inherits org.corpus_tools.salt.util.internal.AbstractDiff< SDocumentGraph >.
|
boolean | findDiffs (boolean diffsRequested) |
| Compares the set graphs and returns if they are isomorphic or not. More...
|
|
boolean | compareRelations (SDocumentGraph template, List<? extends SRelation > templateRels, SDocumentGraph other, List<? extends SRelation > otherRels, Boolean diff) |
| Compares all SPointingRelation of other and template graph. More...
|
|
boolean | compareLayers (SDocumentGraph template, SDocumentGraph other, Boolean diff) |
| Compares all layers in template graph with all layers in other graph and searches for isomorphic partners. More...
|
|
BiMap< SNode, SNode > | getIsoNodes () |
| Return BiMap with isomorphic SNodes key= template, value= other. More...
|
|
Set< Difference > | getDifferences () |
| Returns a list containing all computed differences. More...
|
|
void | addDifference (final Object templateObject, final Object otherObject, final Object container, final DIFF_TYPES diffType, final Set< Difference > subDiffs) |
| Adds a difference to the differences set. More...
|
|
abstract boolean | findDiffs (boolean diffsRequested) |
|
boolean | compareIdentifiableElements (final IdentifiableElement template, final IdentifiableElement other, final Set< Difference > subDiffs) |
| Checks whether two IdentifiableElement objects are isomorph. More...
|
|
boolean | compareAnnotationContainers (final SAnnotationContainer template, final SAnnotationContainer other, final Set< Difference > subDiffs) |
| Checks whether two SAnnotationContainer objects are isomorph and returns true if this is the case, false otherwise. More...
|
|
|
final S | templateObject |
|
final S | otherObject |
|
final DiffOptions | options |
|
Set< Difference > | differences |
|
boolean | diffsRequested |
| if false, only isomorphie is computed, which makes the process faster but does not collect all differences
|
|
◆ DocumentStructureDiff()
Initializes Diff object with the two graphs template
and other
.
- Parameters
-
◆ compareLayers()
boolean org.corpus_tools.salt.util.internal.DocumentStructureDiff.compareLayers |
( |
SDocumentGraph |
template, |
|
|
SDocumentGraph |
other, |
|
|
Boolean |
diff |
|
) |
| |
|
protected |
Compares all layers in template graph with all layers in other graph and searches for isomorphic partners.
To layers are isomorph, when have the same name and contain the same number of nodes and relations and have the same labels.
When diff is true, the return value is not necessarily correct, since in that case the differences in getDifferences() is computed. To check the isomorphie there must be no differences.
- Parameters
-
- Returns
◆ compareRelations()
Compares all SPointingRelation of other and template graph.
When diff is true, the return value is not necessarily correct, since in that case the differences in getDifferences() is computed. To check the isomorphie there must be no differences.
- Parameters
-
- Returns
◆ findDiffs()
boolean org.corpus_tools.salt.util.internal.DocumentStructureDiff.findDiffs |
( |
boolean |
diffsRequested | ) |
|
|
protected |
Compares the set graphs and returns if they are isomorphic or not.
If graphs are not isomporphic, this method finds and records all differences and lists them. This means the entire graphs have to be compared and could slow down the computation. If you are only interested in the result and not in the particular differences, use method isIsomorph().
- Parameters
-
diffsRequested | if false, only isomorphie is computed, which makes the process faster but does not collect all differences |
- Returns
- true, if graphs are isomorphic, false otherwise.