Class ProjectsComparator
java.lang.Object
com.nomagic.magicdraw.tests.common.comparators.ProjectsComparator
Class for comparing two projects. Model and symbols comparison is supported.
-
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptionboolean
Check if two given MagicDraw projects are equals by comparing their model elements and diagrams.DiagramComparator used for comparing project diagrams during projects comparison.ModelComparator implementation used for projects comparison.void
setDiagramComparator
(DiagramComparator diagramComparator) Sets DiagramComparator implementation for comparing project diagrams during projects comparison.void
setLogTextEnd
(String text) Text to add before projects comparison log.void
setModelComparator
(ModelComparator comparator) Set implementation of ModelComparator to use for projects comparison.
-
Constructor Details
-
ProjectsComparator
public ProjectsComparator()
-
-
Method Details
-
compare
Check if two given MagicDraw projects are equals by comparing their model elements and diagrams.- Parameters:
prj1
- first MagicDraw project to compare.prj2
- second MagicDraw project to compare.- Returns:
- true if given MagicDraw projects are equals, false otherwise.
-
getModelComparator
ModelComparator implementation used for projects comparison.- Returns:
- implementation of ModelComparator used for projects comparison or null if projects compared using other criterion.
-
setModelComparator
Set implementation of ModelComparator to use for projects comparison.- Parameters:
comparator
- implementation of ModelComparator to use for projects comparison.
-
getDiagramComparator
DiagramComparator used for comparing project diagrams during projects comparison.- Returns:
- implementation of DiagramComparator used for comparing diagrams or null if projects are compared by other criterion.
-
setDiagramComparator
Sets DiagramComparator implementation for comparing project diagrams during projects comparison.- Parameters:
diagramComparator
- implementation of DiagramComparator use for project diagrams comparison.
-
setLogTextEnd
Text to add before projects comparison log.- Parameters:
text
- String text to add.
-