Class GenericTypeBinder
java.lang.Object
org.benf.cfr.reader.bytecode.analysis.types.GenericTypeBinder
FIXME - this class has multiple ways of implementing the same thing - definitely feels redundant!
-
Field Summary
Fields -
Constructor Summary
ConstructorsModifierConstructorDescriptionprivate
GenericTypeBinder
(Map<String, JavaTypeInstance> nameToBoundType) -
Method Summary
Modifier and TypeMethodDescription(package private) static GenericTypeBinder
bind
(List<FormalTypeParameter> methodFormalTypeParameters, ClassSignature classSignature, List<JavaTypeInstance> args, JavaGenericRefTypeInstance boundInstance, List<JavaTypeInstance> boundArgs) static GenericTypeBinder
static GenericTypeBinder
create
(List<FormalTypeParameter>... ftps) createAssignmentRhsBindings
(GenericTypeBinder rhsBinder) static GenericTypeBinder
private static void
doBind
(Map<String, JavaTypeInstance> boundNames, JavaGenericBaseInstance unbound, JavaTypeInstance maybeBound) static GenericTypeBinder
extractBaseBindings
(JavaGenericBaseInstance unbound, JavaTypeInstance maybeBound) static GenericTypeBinder
extractBindings
(JavaGenericBaseInstance unbound, JavaTypeInstance maybeBound) (package private) JavaTypeInstance
getBindingFor
(FormalTypeParameter formalTypeParameter) getBindingFor
(JavaTypeInstance maybeUnbound) private static boolean
isBetterBinding
(JavaTypeInstance isBetter, JavaTypeInstance than) mergeWith
(GenericTypeBinder other, boolean mergeToCommonClass) void
void
suggestBindingFor
(String name, JavaTypeInstance binding) void
-
Field Details
-
nameToBoundType
-
-
Constructor Details
-
GenericTypeBinder
-
-
Method Details
-
createEmpty
-
create
-
bind
static GenericTypeBinder bind(List<FormalTypeParameter> methodFormalTypeParameters, ClassSignature classSignature, List<JavaTypeInstance> args, JavaGenericRefTypeInstance boundInstance, List<JavaTypeInstance> boundArgs) -
buildIdentityBindings
-
extractBaseBindings
public static GenericTypeBinder extractBaseBindings(JavaGenericBaseInstance unbound, JavaTypeInstance maybeBound) -
extractBindings
public static GenericTypeBinder extractBindings(JavaGenericBaseInstance unbound, JavaTypeInstance maybeBound) -
doBind
private static void doBind(Map<String, JavaTypeInstance> boundNames, JavaGenericBaseInstance unbound, JavaTypeInstance maybeBound) -
removeBinding
-
getBindingFor
-
getBindingFor
-
isBetterBinding
-
suggestOnlyNullBinding
-
suggestBindingFor
-
mergeWith
-
createAssignmentRhsBindings
-