Package org.hl7.fhir.dstu2.utils
Class ProfileComparer
- java.lang.Object
-
- org.hl7.fhir.dstu2.utils.ProfileComparer
-
public class ProfileComparer extends Object
A engine that generates difference analysis between two sets of structure definitions, typically from 2 different implementation guides. How this class works is that you create it with access to a bunch of underying resources that includes all the structure definitions from both implementation guides Once the class is created, you repeatedly pass pairs of structure definitions, one from each IG, building up a web of difference analyses. This class will automatically process any internal comparisons that it encounters When all the comparisons have been performed, you can then generate a variety of output formats- Author:
- Grahame Grieve
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description classProfileComparer.ProfileComparison
-
Constructor Summary
Constructors Constructor Description ProfileComparer(IWorkerContext context)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description StringaddValueSet(ValueSet cvs)ProfileComparer.ProfileComparisoncompareProfiles(StructureDefinition left, StructureDefinition right)Compare left and right structure definitions to see whether they are consistent or not Note that left and right are arbitrary choices.List<ProfileComparer.ProfileComparison>getComparisons()StringgetId()StringgetLeftLink()StringgetLeftName()StringgetRightLink()StringgetRightName()StringgetTitle()List<ValueSet>getValuesets()voidsetId(String id)voidsetLeftLink(String leftLink)voidsetLeftName(String leftName)voidsetRightLink(String rightLink)voidsetRightName(String rightName)voidsetTitle(String title)voidstatus(ElementDefinition ed, int value)
-
-
-
Constructor Detail
-
ProfileComparer
public ProfileComparer(IWorkerContext context)
-
-
Method Detail
-
getValuesets
public List<ValueSet> getValuesets()
-
status
public void status(ElementDefinition ed, int value)
-
getComparisons
public List<ProfileComparer.ProfileComparison> getComparisons()
-
compareProfiles
public ProfileComparer.ProfileComparison compareProfiles(StructureDefinition left, StructureDefinition right) throws org.hl7.fhir.exceptions.DefinitionException, IOException
Compare left and right structure definitions to see whether they are consistent or not Note that left and right are arbitrary choices. In one respect, left is 'preferred' - the left's example value and data sets will be selected over the right ones in the common structure definition- Throws:
org.hl7.fhir.exceptions.DefinitionExceptionIOException
-
addValueSet
public String addValueSet(ValueSet cvs)
-
getLeftLink
public String getLeftLink()
-
setLeftLink
public void setLeftLink(String leftLink)
-
getLeftName
public String getLeftName()
-
setLeftName
public void setLeftName(String leftName)
-
getRightLink
public String getRightLink()
-
setRightLink
public void setRightLink(String rightLink)
-
getRightName
public String getRightName()
-
setRightName
public void setRightName(String rightName)
-
-