public abstract class ParamTypeSystem_c<Formal extends Param,Actual extends TypeObject> extends TypeSystem_c implements ParamTypeSystem<Formal,Actual>
TypeSystem_c.MostSpecificComparator<T extends ProcedureInstance>
Modifier and Type | Field and Description |
---|---|
protected java.util.Map<java.util.Map<Formal,? extends Actual>,Subst<Formal,Actual>> |
substCache |
ABSTRACT_METHOD_FLAGS, ACCESS_FLAGS, BOOLEAN_, BYTE_, CHAR_, CLASS_, CONSTRUCTOR_FLAGS, DOUBLE_, extInfo, FIELD_FLAGS, flagsForName, FLOAT_, INITIALIZER_FLAGS, INT_, INTERFACE_FIELD_FLAGS, loadedResolver, LOCAL_CLASS_FLAGS, LOCAL_FLAGS, LONG_, MEMBER_CLASS_FLAGS, METHOD_FLAGS, NULL_, OBJECT_, SHORT_, STRING_, systemResolver, THROWABLE_, TOP_LEVEL_CLASS_FLAGS, unknownPackage, unknownQualifier, unknownType, VOID_
SERIALIZE_MEMBERS_WITH_CONTAINER
Constructor and Description |
---|
ParamTypeSystem_c() |
Modifier and Type | Method and Description |
---|---|
protected void |
checkInstantiation(Position pos,
PClass<Formal,Actual> base,
java.util.List<? extends Actual> actuals)
Check that an instantiation of a parametric type on a list of actual
parameters is legal.
|
ClassType |
instantiate(Position pos,
PClass<Formal,Actual> base,
java.util.List<? extends Actual> actuals)
Instantiate a parametric type on a list of actual parameters.
|
MuPClass<Formal,Actual> |
mutablePClass(Position pos)
Create a new mutable PClass.
|
Subst<Formal,Actual> |
subst(java.util.Map<Formal,? extends Actual> substMap)
Create a substituter.
|
Type |
subst(Type t,
java.util.Map<Formal,? extends Actual> substMap)
Apply a parameter substitution to a type.
|
protected Subst<Formal,Actual> |
substImpl(java.util.Map<Formal,? extends Actual> substMap) |
protected ClassType |
uncheckedInstantiate(Position pos,
PClass<Formal,Actual> base,
java.util.List<? extends Actual> actuals)
Instantiate a parametric type on a list of actual parameters, but
do not check that the instantiation is legal.
|
Abstract, abstractSuperInterfaces, accessibleFromPackage, ArithmeticException, arrayOf, arrayOf, arrayOf, arrayOf, ArrayStoreException, arrayType, assert_, assert_, Boolean, Byte, callValid, canCoerceToString, canOverride, Char, checkAccessFlags, checkClassConformance, checkClassFlagsConflict, checkConstructorFlags, checkCycles, checkCycles, checkFieldFlags, checkInitializerFlags, checkInterfaceFieldFlags, checkLocalClassFlags, checkLocalFlags, checkMemberClassFlags, checkMethodFlags, checkOverride, checkTopLevelClassFlags, Class, classAccessible, classAccessible, classAccessibleFromPackage, ClassCastException, classContextResolver, classContextResolver, classFileLazyClassInitializer, Cloneable, constructorInstance, createArrayType, createClassContextResolver, createClassType, createClassType, createClassType, createClassType, createContext, createNewFlag, createNull, createPackage, createPackage, createPackageContextResolver, createPrimitive, defaultClassInitializer, defaultConstructor, defaultPackageImports, descendsFrom, deserializedClassInitializer, Double, equals, Error, Exception, extensionInfo, fieldInstance, Final, findAcceptableConstructors, findAcceptableMethods, findConstructor, findConstructor, findConstructor, findField, findField, findField, findField, findFields, findImplementingMethod, findMemberClass, findMemberClass, findMemberClass, findMethod, findMethod, findMethod, findMostSpecificProcedures, findProcedure, flagsForBits, flagsForName, Float, forName, forName, getTransformedClassName, getTypeEncoderRootSet, hasAccessibleMethodNamed, hasEnclosingInstance, hasFormals, hasMethod, hasMethodNamed, implemented, importTable, importTable, initEnums, initFlags, initialize, initializerInstance, initTypes, Int, Interface, interfaces, isAccessible, isAccessible, isAccessible, isAccessible, isAccessible, isCanonical, isCastValid, isEnclosed, isImplicitCastValid, isInherited, isMember, isSameMethod, isSubtype, isThrowable, isUncheckedException, leastCommonAncestor, legalAbstractMethodFlags, legalAccessFlags, legalConstructorFlags, legalFieldFlags, legalInitializerFlags, legalInterfaceFieldFlags, legalLocalClassFlags, legalLocalFlags, legalMemberClassFlags, legalMethodFlags, legalTopLevelClassFlags, listToString, load, loadedResolver, localInstance, Long, methodCallValid, methodInstance, moreSpecific, Native, NoFlags, Null, NullPointerException, numericConversionValid, numericConversionValid, Object, OutOfBoundsException, overrides, packageContextResolver, packageContextResolver, packageContextResolver, packageEquals, packageExists, packageForName, packageForName, parsedResolver, placeHolder, placeHolder, primitiveForName, Private, promote, promote, promoteNumeric, promoteNumeric, Protected, Public, restoreSystemResolver, returnTypesConsistent, RuntimeException, saveSystemResolver, Serializable, Short, Static, staticTarget, StrictFP, String, superType, Synchronized, systemResolver, Throwable, throwsSubset, toString, Transient, translateArray, translateClass, translatePackage, translatePrimitive, typeEquals, typeForClass, typeForClass, typeForName, uncheckedExceptions, unknownPackage, unknownQualifier, unknownType, Void, Volatile, wrapperTypeString
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
Abstract, ArithmeticException, arrayOf, arrayOf, arrayOf, arrayOf, ArrayStoreException, Boolean, Byte, callValid, canCoerceToString, canOverride, Char, checkAccessFlags, checkClassConformance, checkConstructorFlags, checkCycles, checkFieldFlags, checkInitializerFlags, checkInterfaceFieldFlags, checkLocalClassFlags, checkLocalFlags, checkMemberClassFlags, checkMethodFlags, checkOverride, checkTopLevelClassFlags, Class, classAccessible, classAccessible, classAccessibleFromPackage, ClassCastException, classContextResolver, classContextResolver, classFileLazyClassInitializer, Cloneable, constructorInstance, createClassContextResolver, createClassType, createClassType, createClassType, createClassType, createContext, createNewFlag, createPackage, createPackage, createPackageContextResolver, defaultClassInitializer, defaultConstructor, defaultPackageImports, descendsFrom, deserializedClassInitializer, Double, equals, Error, Exception, extensionInfo, fieldInstance, Final, findConstructor, findConstructor, findConstructor, findField, findField, findField, findField, findImplementingMethod, findMemberClass, findMemberClass, findMemberClass, findMethod, findMethod, findMethod, flagsForBits, Float, forName, getTransformedClassName, getTypeEncoderRootSet, hasAccessibleMethodNamed, hasEnclosingInstance, hasFormals, hasMethod, hasMethodNamed, implemented, importTable, importTable, initialize, initializerInstance, Int, Interface, interfaces, isAccessible, isAccessible, isAccessible, isAccessible, isAccessible, isCanonical, isCastValid, isEnclosed, isImplicitCastValid, isInherited, isMember, isSameMethod, isSubtype, isThrowable, isUncheckedException, leastCommonAncestor, legalAbstractMethodFlags, legalAccessFlags, legalConstructorFlags, legalFieldFlags, legalInitializerFlags, legalInterfaceFieldFlags, legalLocalClassFlags, legalLocalFlags, legalMemberClassFlags, legalMethodFlags, legalTopLevelClassFlags, loadedResolver, localInstance, Long, methodCallValid, methodInstance, moreSpecific, Native, NoFlags, Null, NullPointerException, numericConversionValid, numericConversionValid, Object, OutOfBoundsException, overrides, packageContextResolver, packageContextResolver, packageContextResolver, packageEquals, packageExists, packageForName, packageForName, parsedResolver, placeHolder, placeHolder, primitiveForName, Private, promote, promote, Protected, Public, restoreSystemResolver, RuntimeException, saveSystemResolver, Serializable, Short, Static, staticTarget, StrictFP, String, superType, Synchronized, systemResolver, Throwable, throwsSubset, Transient, translateArray, translateClass, translatePackage, translatePrimitive, typeEquals, typeForName, uncheckedExceptions, unknownPackage, unknownQualifier, unknownType, Void, Volatile, wrapperTypeString
protected java.util.Map<java.util.Map<Formal extends Param,? extends Actual extends TypeObject>,Subst<Formal extends Param,Actual extends TypeObject>> substCache
public MuPClass<Formal,Actual> mutablePClass(Position pos)
ParamTypeSystem
mutablePClass
in interface ParamTypeSystem<Formal extends Param,Actual extends TypeObject>
pos
- The position of the PClasspublic ClassType instantiate(Position pos, PClass<Formal,Actual> base, java.util.List<? extends Actual> actuals) throws SemanticException
ParamTypeSystem
instantiate
in interface ParamTypeSystem<Formal extends Param,Actual extends TypeObject>
pos
- The position of the instantiated typebase
- The parameterized typeactuals
- The list of actualsSemanticException
- when the actuals do not agree with the formalsprotected void checkInstantiation(Position pos, PClass<Formal,Actual> base, java.util.List<? extends Actual> actuals) throws SemanticException
pos
- The position of the instantiated typebase
- The parameterized typeactuals
- The list of actualsSemanticException
- when the actuals do not agree with the formalsprotected ClassType uncheckedInstantiate(Position pos, PClass<Formal,Actual> base, java.util.List<? extends Actual> actuals)
pos
- The position of the instantiated typebase
- The parameterized typeactuals
- The list of actualspublic Type subst(Type t, java.util.Map<Formal,? extends Actual> substMap)
ParamTypeSystem
subst
in interface ParamTypeSystem<Formal extends Param,Actual extends TypeObject>
t
- The type on which we perform substitutions.substMap
- Map from formal parameters to actuals; the formals are
not necessarily formals of t
.public final Subst<Formal,Actual> subst(java.util.Map<Formal,? extends Actual> substMap)
ParamTypeSystem
subst
in interface ParamTypeSystem<Formal extends Param,Actual extends TypeObject>
substMap
- Map from formal parameters to actuals.