ElementQualifierHierarchy
instead.@Deprecated public static class MultiGraphQualifierHierarchy.MultiGraphFactory extends Object
GraphQualifierHierarchy
. A factory can be used
to create at most one GraphQualifierHierarchy
.
To create a hierarchy, a client may do so in three steps:
addQualifier(AnnotationMirror)
;
addSubtype(AnnotationMirror, AnnotationMirror)
build()
.
addSubtype(AnnotationMirror, AnnotationMirror)
adds the two qualifiers
to the hierarchy if they are not already in.
Also, once the client builds a hierarchy through build()
, no further
modifications are allowed nor can it making a new instance.
Clients build the hierarchy using addQualifier(AnnotationMirror)
and addSubtype(AnnotationMirror, AnnotationMirror)
, then get the instance with calling build()
Modifier and Type | Field and Description |
---|---|
protected AnnotatedTypeFactory |
atypeFactory
Deprecated.
The annotated type factory associated with this hierarchy.
|
protected Map<AnnotationMirror,AnnotationMirror> |
polyQualifiers
Deprecated.
Map from qualifier hierarchy to the corresponding polymorphic qualifier.
|
protected Map<AnnotationMirror,Set<AnnotationMirror>> |
supertypesDirect
Deprecated.
Map from qualifiers to the direct supertypes of the qualifier.
|
Constructor and Description |
---|
MultiGraphFactory(AnnotatedTypeFactory atypeFactory)
Deprecated.
Create a factory.
|
Modifier and Type | Method and Description |
---|---|
void |
addQualifier(AnnotationMirror qual)
Deprecated.
Adds the passed qualifier to the hierarchy.
|
void |
addSubtype(AnnotationMirror sub,
AnnotationMirror sup)
Deprecated.
Adds a subtype relationship between the two type qualifiers.
|
protected void |
assertNotBuilt()
Deprecated.
Throw an exception if the factory was already built.
|
QualifierHierarchy |
build()
Deprecated.
Returns an instance of
GraphQualifierHierarchy that represents the hierarchy
built so far. |
protected QualifierHierarchy |
createQualifierHierarchy()
Deprecated.
Create
QualifierHierarchy |
protected final Map<AnnotationMirror,Set<AnnotationMirror>> supertypesDirect
protected final Map<AnnotationMirror,AnnotationMirror> polyQualifiers
protected final AnnotatedTypeFactory atypeFactory
public MultiGraphFactory(AnnotatedTypeFactory atypeFactory)
public void addQualifier(AnnotationMirror qual)
addSubtype(AnnotationMirror, AnnotationMirror)
.public void addSubtype(AnnotationMirror sub, AnnotationMirror sup)
sub
- the sub type qualifiersup
- the super type qualifierpublic QualifierHierarchy build()
GraphQualifierHierarchy
that represents the hierarchy
built so far.protected QualifierHierarchy createQualifierHierarchy()
QualifierHierarchy
protected void assertNotBuilt()