public class UnitsRelationsDefault extends Object implements UnitsRelations
| Modifier and Type | Field and Description | 
|---|---|
| protected Elements | elementsThe Element Utilities from the Units Checker's processing environment. | 
| protected AnnotationMirror | gSI base units. | 
| protected AnnotationMirror | hNon-SI units | 
| protected AnnotationMirror | kgSI base units. | 
| protected AnnotationMirror | kmSI base units. | 
| protected AnnotationMirror | km2Derived SI units without special names | 
| protected AnnotationMirror | km3Derived SI units without special names | 
| protected AnnotationMirror | kmPERhNon-SI units | 
| protected AnnotationMirror | kNDerived SI units with special names | 
| protected AnnotationMirror | mSI base units. | 
| protected AnnotationMirror | m2Derived SI units without special names | 
| protected AnnotationMirror | m3Derived SI units without special names | 
| protected AnnotationMirror | mmSI base units. | 
| protected AnnotationMirror | mm2Derived SI units without special names | 
| protected AnnotationMirror | mm3Derived SI units without special names | 
| protected AnnotationMirror | mPERsDerived SI units without special names | 
| protected AnnotationMirror | mPERs2Derived SI units without special names | 
| protected AnnotationMirror | NDerived SI units with special names | 
| protected AnnotationMirror | sSI base units. | 
| protected AnnotationMirror | tNon-SI units | 
| Constructor and Description | 
|---|
| UnitsRelationsDefault() | 
| Modifier and Type | Method and Description | 
|---|---|
| protected boolean | bothHaveSpecificPrefix(Prefix lhtPrefix,
                      Prefix rhtPrefix,
                      Prefix specificPrefix)Checks to see if both lhtPrefix and rhtPrefix have the same prefix as specificPrefix. | 
| @Nullable AnnotationMirror | division(AnnotatedTypeMirror lht,
        AnnotatedTypeMirror rht)Provides rules for resolving the result Unit of the division of checker-framework provided
 Units. | 
| protected boolean | havePairOfUnits(AnnotatedTypeMirror lht,
               AnnotationMirror ul,
               AnnotatedTypeMirror rht,
               AnnotationMirror ur)Checks to see if lht has the unit ul and if rht has the unit ur all at the same time. | 
| protected boolean | havePairOfUnitsIgnoringOrder(AnnotatedTypeMirror lht,
                            AnnotationMirror u1,
                            AnnotatedTypeMirror rht,
                            AnnotationMirror u2)Checks to see if lht and rht have the pair of units u1 and u2 regardless of order. | 
| UnitsRelations | init(ProcessingEnvironment env)Constructs various AnnotationMirrors representing specific checker-framework provided Units
 involved in the rules resolved in this UnitsRelations implementation. | 
| @Nullable AnnotationMirror | multiplication(AnnotatedTypeMirror lht,
              AnnotatedTypeMirror rht)Provides rules for resolving the result Unit of the multiplication of checker-framework
 provided Units. | 
protected AnnotationMirror m
protected AnnotationMirror km
protected AnnotationMirror mm
protected AnnotationMirror s
protected AnnotationMirror g
protected AnnotationMirror kg
protected AnnotationMirror m2
protected AnnotationMirror km2
protected AnnotationMirror mm2
protected AnnotationMirror m3
protected AnnotationMirror km3
protected AnnotationMirror mm3
protected AnnotationMirror mPERs
protected AnnotationMirror mPERs2
protected AnnotationMirror N
protected AnnotationMirror kN
protected AnnotationMirror h
protected AnnotationMirror kmPERh
protected AnnotationMirror t
protected Elements elements
public UnitsRelations init(ProcessingEnvironment env)
init in interface UnitsRelationsenv - the ProcessingEnvironment to usepublic @Nullable AnnotationMirror multiplication(AnnotatedTypeMirror lht, AnnotatedTypeMirror rht)
multiplication in interface UnitsRelationslht - left hand side in multiplicationrht - right hand side in multiplicationpublic @Nullable AnnotationMirror division(AnnotatedTypeMirror lht, AnnotatedTypeMirror rht)
division in interface UnitsRelationslht - left hand side in divisionrht - right hand side in divisionprotected boolean bothHaveSpecificPrefix(Prefix lhtPrefix, Prefix rhtPrefix, Prefix specificPrefix)
lhtPrefix - left hand side prefixrhtPrefix - right hand side prefixspecificPrefix - specific desired prefix to matchprotected boolean havePairOfUnits(AnnotatedTypeMirror lht, AnnotationMirror ul, AnnotatedTypeMirror rht, AnnotationMirror ur)
lht - left hand annotated typeul - left hand unitrht - right hand annotated typeur - right hand unitprotected boolean havePairOfUnitsIgnoringOrder(AnnotatedTypeMirror lht, AnnotationMirror u1, AnnotatedTypeMirror rht, AnnotationMirror u2)
lht - left hand annotated typeu1 - unit 1rht - right hand annotated typeu2 - unit 2