public class TypeLoaderAccess extends BaseService implements ITypeSystem
| Modifier and Type | Field and Description |
|---|---|
static LockingLazyVar<Map<String,IJavaType>> |
PRIMITIVE_TYPES_BY_NAME |
| Constructor and Description |
|---|
TypeLoaderAccess() |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitgetInterfacepublic static LockingLazyVar<Map<String,IJavaType>> PRIMITIVE_TYPES_BY_NAME
public static TypeLoaderAccess instance()
public Module getCurrentModule()
getCurrentModule in interface ITypeSystempublic void pushModule(IModule module)
pushModule in interface ITypeSystempublic void popModule(IModule module)
popModule in interface ITypeSystempublic IGosuc makeGosucCompiler(String gosucProjectFile, ICustomParser custParser)
makeGosucCompiler in interface ITypeSystempublic boolean isParameterizedWith(IType type, ITypeVariableType... typeVars)
isParameterizedWith in interface ITypeSystempublic IType getCompoundType(Set<IType> types)
getCompoundType in interface ITypeSystempublic List<ITypeLoader> getAllTypeLoaders()
getAllTypeLoaders in interface ITypeSystempublic void pushTypeLoader(IModule module, ITypeLoader typeLoader)
pushTypeLoader in interface ITypeSystempublic void removeTypeLoader(Class<? extends ITypeLoader> loaderType)
removeTypeLoader in interface ITypeSystempublic ITypeRef getTypeReference(IType type)
getTypeReference in interface ITypeSystempublic ITypeRef getOrCreateTypeReference(IType type)
getOrCreateTypeReference in interface ITypeSystempublic <T extends ITypeLoader> T getTypeLoader(Class<? extends T> loaderType, IModule module)
getTypeLoader in interface ITypeSystempublic INamespaceType getNamespace(String strFqNamespace)
getNamespace in interface ITypeSystempublic IType getIntrinsicTypeByFullName(String fullyQualifiedName) throws ClassNotFoundException
ClassNotFoundExceptionpublic IType getByRelativeName(String relativeName, ITypeUsesMap typeUses) throws ClassNotFoundException
getByRelativeName in interface ITypeSystemrelativeName - the relative name of the typetypeUses - the map of used types to use when resolvingClassNotFoundException - if the specified name doesn't correspond to any typepublic IType getTypeByRelativeNameIfValid_NoGenerics(String relativeName, ITypeUsesMap typeUses)
public Set<? extends CharSequence> getAllTypeNames()
getAllTypeNames in interface ITypeSystempublic void clearErrorTypes()
clearErrorTypes in interface ITypeSystempublic void refresh(boolean clearCachedTypes)
refresh in interface ITypeSystempublic void shutdown()
shutdown in interface ITypeSystempublic void refreshTypes(RefreshRequest request)
public int getRefreshChecksum()
getRefreshChecksum in interface ITypeSystempublic int getSingleRefreshChecksum()
getSingleRefreshChecksum in interface ITypeSystempublic void addTypeLoaderListenerAsWeakRef(ITypeLoaderListener l)
Note! Callers must manage the lifecycle of the listener, otherwise since this method creates a weak ref, it will be collected when it goes out of scope.
addTypeLoaderListenerAsWeakRef in interface ITypeSysteml - Your type loader listenerpublic void removeTypeLoaderListener(ITypeLoaderListener l)
removeTypeLoaderListener in interface ITypeSystempublic void incrementChecksums()
public void addShutdownListener(TypeSystemShutdownListener listener)
addShutdownListener in interface ITypeSystempublic IType get(Class<?> javaClass)
Note: you should use this method only if you do not have an Object of class
javaClass to get the type from. If you
do have such an object, use getFromObject(java.lang.Object) instead.get in interface ITypeSystemjavaClass - the Class to convert to an intrinsic typegetFromObject(Object)public IType get(IJavaClassInfo javaClassInfo)
get in interface ITypeSystempublic IType getFromObject(Object object)
getFromObject in interface ITypeSystemobject - the object to get an IType forget(Class)public IType getByRelativeName(String relativeName) throws ClassNotFoundException
getByRelativeName in interface ITypeSystemClassNotFoundExceptionpublic IType getByFullName(String fullyQualifiedName)
getByFullName in interface ITypeSystemfullyQualifiedName - the fully qualified name of the typeRuntimeException - if the specified name doesn't correspond to any typepublic IType getByFullNameIfValid(String fullyQualifiedName)
getByFullNameIfValid in interface ITypeSystemfullyQualifiedName - the fully qualified name of the typepublic IType getByFullNameIfValidNoJava(String fullyQualifiedName)
getByFullNameIfValidNoJava in interface ITypeSystempublic IType boundTypes(IType targetType, List<IType> typesToBound)
boundTypes in interface ITypeSystempublic void refresh(ITypeRef typeRef)
refresh in interface ITypeSystempublic void refresh(IModule module)
refresh in interface ITypeSystempublic void refreshed(IResource file, String typeName, RefreshKind refreshKind)
refreshed in interface ITypeSystempublic String[] getTypesForFile(IModule module, IFile file)
getTypesForFile in interface ITypeSystempublic IType parseType(String typeString) throws IllegalArgumentException
parseType in interface ITypeSystemIllegalArgumentException - if the type string doesn't correspond to any known ITypepublic IType parseType(String typeString, ITypeUsesMap typeUsesMap) throws IllegalArgumentException
parseType in interface ITypeSystemIllegalArgumentExceptionpublic IType parseType(String typeString, TypeVarToTypeMap actualParamByVarName)
parseType in interface ITypeSystempublic IType parseType(String typeString, TypeVarToTypeMap actualParamByVarName, ITypeUsesMap typeUsesMap)
parseType in interface ITypeSystempublic ITypeLiteralExpression parseTypeExpression(String typeString, TypeVarToTypeMap actualParamByVarName, ITypeUsesMap typeUsesMap) throws ParseResultsException
parseTypeExpression in interface ITypeSystemParseResultsExceptionpublic IType getComponentType(IType valueType)
getComponentType in interface ITypeSystempublic ITypeVariableType getOrCreateTypeVariableType(String strName, IType boundingType, IType enclosingType)
getOrCreateTypeVariableType in interface ITypeSystempublic IFunctionType getOrCreateFunctionType(IMethodInfo mi)
getOrCreateFunctionType in interface ITypeSystempublic IFunctionType getOrCreateFunctionType(String strFunctionName, IType retType, IType[] paramTypes)
getOrCreateFunctionType in interface ITypeSystempublic TypeVarToTypeMap mapTypeByVarName(IType ownersType, IType declaringType)
mapTypeByVarName in interface ITypeSystempublic IType getActualType(IType type, TypeVarToTypeMap actualParamByVarName, boolean bKeepTypeVars)
getActualType in interface ITypeSystempublic void inferTypeVariableTypesFromGenParamTypeAndConcreteType(IType genParamType, IType argType, TypeVarToTypeMap map)
inferTypeVariableTypesFromGenParamTypeAndConcreteType in interface ITypeSystempublic void inferTypeVariableTypesFromGenParamTypeAndConcreteType_Reverse(IType genParamType, IType argType, TypeVarToTypeMap map)
inferTypeVariableTypesFromGenParamTypeAndConcreteType_Reverse in interface ITypeSystempublic IErrorType getErrorType()
getErrorType in interface ITypeSystempublic IErrorType getErrorType(String strErrantName)
getErrorType in interface ITypeSystempublic IErrorType getErrorType(ParseResultsException pe)
getErrorType in interface ITypeSystempublic IDefaultTypeLoader getDefaultTypeLoader()
getDefaultTypeLoader in interface ITypeSystempublic IType findParameterizedType(IType type, IType rhsType)
findParameterizedType in interface ITypeSystempublic Set<String> getNamespacesFromTypeNames(Set<? extends CharSequence> allTypeNames, Set<String> namespaces)
getNamespacesFromTypeNames in interface ITypeSystempublic void pushTypeLoader(ITypeLoader loader)
pushTypeLoader in interface ITypeSystempublic void pushIncludeAll()
pushIncludeAll in interface ITypeSystempublic void popIncludeAll()
popIncludeAll in interface ITypeSystempublic boolean isIncludeAll()
isIncludeAll in interface ITypeSystempublic IType getCurrentCompilingType()
getCurrentCompilingType in interface ITypeSystempublic void pushCompilingType(IType type)
pushCompilingType in interface ITypeSystempublic void popCompilingType()
popCompilingType in interface ITypeSystempublic IType getCompilingType(String strName)
getCompilingType in interface ITypeSystempublic void pushSymTableCtx(ISymbolTable ctx)
pushSymTableCtx in interface ITypeSystempublic void popSymTableCtx()
popSymTableCtx in interface ITypeSystempublic ISymbolTable getSymTableCtx()
getSymTableCtx in interface ITypeSystempublic IType getTypeFromObject(Object obj)
getTypeFromObject in interface ITypeSystempublic boolean isExpandable(IType type)
isExpandable in interface ITypeSystempublic String getNameOfParams(IType[] paramTypes, boolean bRelative, boolean bWithEnclosingType)
getNameOfParams in interface ITypeSystempublic ISymbolTable getCompiledGosuClassSymbolTable()
getCompiledGosuClassSymbolTable in interface ITypeSystempublic IType getJavaType(Class javaClass)
getJavaType in interface ITypeSystempublic String getNameWithQualifiedTypeVariables(IType type)
getNameWithQualifiedTypeVariables in interface ITypeSystempublic IType getDefaultParameterizedType(IType type)
getDefaultParameterizedType in interface ITypeSystempublic IType getDefaultParameterizedTypeWithTypeVars(IType type)
getDefaultParameterizedTypeWithTypeVars in interface ITypeSystempublic boolean canCast(IType lhsType, IType rhsType)
canCast in interface ITypeSystempublic IJavaType getPrimitiveType(String name)
getPrimitiveType in interface ITypeSystempublic IType getPrimitiveType(IType boxType)
getPrimitiveType in interface ITypeSystempublic IType getBoxType(IType primitiveType)
getBoxType in interface ITypeSystempublic IType getExpandableComponentType(IType type)
getExpandableComponentType in interface ITypeSystempublic IExecutionEnvironment getExecutionEnvironment()
getExecutionEnvironment in interface ITypeSystempublic IExecutionEnvironment getExecutionEnvironment(IProject project)
getExecutionEnvironment in interface ITypeSystempublic IGosuClassLoader getGosuClassLoader()
getGosuClassLoader in interface ITypeSystempublic void dumpGosuClassLoader()
dumpGosuClassLoader in interface ITypeSystempublic IType replaceTypeVariableTypeParametersWithBoundingTypes(IType type, IType enclosingType)
replaceTypeVariableTypeParametersWithBoundingTypes in interface ITypeSystempublic IMetaType getDefaultType()
getDefaultType in interface ITypeSystemCopyright © 2018. All rights reserved.