Package gw.internal.gosu.parser
Class GosuProgram
java.lang.Object
gw.lang.reflect.AbstractType
gw.lang.reflect.InnerClassCapableType
gw.internal.gosu.parser.GosuClass
gw.internal.gosu.parser.GosuProgram
- All Implemented Interfaces:
ICompilableTypeInternal
,IGosuClassInternal
,IGosuProgramInternal
,IParameterizableType
,IFileRepositoryBasedType
,IHasInnerClass
,ICompilableType
,IGosuClass
,IGosuProgram
,ICanBeAnnotation
,IEnhanceableType
,IEnumData
,IEnumType
,IHasJavaClass
,IType
,Serializable
,Comparable
- Direct Known Subclasses:
GosuTemplateType
- See Also:
-
Nested Class Summary
Nested classes/interfaces inherited from interface gw.lang.reflect.gs.IGosuClass
IGosuClass.ProxyUtil
Nested classes/interfaces inherited from interface gw.internal.gosu.parser.IGosuClassInternal
IGosuClassInternal.Util
Nested classes/interfaces inherited from interface gw.lang.reflect.gs.IGosuProgram
IGosuProgram.Runner
-
Field Summary
FieldsModifier and TypeFieldDescriptionprivate boolean
private boolean
private boolean
private boolean
private boolean
private IType
private ContextInferenceManager
private IType
private IProgramInstance
private boolean
private ITokenizerInstructor
Fields inherited from class gw.internal.gosu.parser.GosuClass
_parseInfo
Fields inherited from interface gw.lang.reflect.gs.IGosuClass
ANONYMOUS_PREFIX, PROXY_PREFIX, SUPER_PROXY_CLASS_PREFIX
Fields inherited from interface gw.lang.reflect.gs.IGosuProgram
NAME_PREFIX, PACKAGE, PACKAGE_PLUS_DOT
Fields inherited from interface gw.lang.reflect.IType
EMPTY_ARRAY, EMPTY_TYPE_ARRAY, EMPTY_TYPE_LIST
-
Constructor Summary
ConstructorsConstructorDescriptionGosuProgram
(String strNamespace, String strRelativeName, GosuClassTypeLoader classTypeLoader, ISourceFileHandle sourceFile, ITypeUsesMap typeUsesMap, ISymbolTable symTable) -
Method Summary
Modifier and TypeMethodDescriptionvoid
addCapturedProgramSymbols
(ISymbolTable classCompilationSymTable) void
addExecuteEntryPoint
(ISymbolTable symTable, GosuClassParser parser) void
addProgramEntryPoint
(ISymbolTable symTable, GosuClassParser parser) private void
addProgramInstanceMethod
(ISymbolTable symTable, GosuClassParser parser, IJavaType cls, String strMethod, IType params) protected void
boolean
void
private boolean
private IProgramInstance
When changing the places from which this method is called run pc's gw.smoketest.pc.job.common.effectivetime.VisibleEffectiveTimeTest cause it will break!evaluate
(IExternalSymbolMap externalSymbols) evaluateRoot
(IExternalSymbolMap externalSymbols) getExternalSymbol
(String strName) protected GosuParser
getOrCreateParser
(CompiledGosuClassSymbolTable symbolTable) boolean
boolean
boolean
boolean
boolean
boolean
boolean
private Object
runProgram
(IExternalSymbolMap externalSymbols) void
setAdditionalDFSDecls
(ISymbolTable symbolTable) void
setAllowUses
(boolean b) void
setAnonymous
(boolean b) void
setContextType
(IType contextType) void
setCtxInferenceMgr
(Object ctxInferenceMgr) void
setEnclosingEvalExpression
(IParsedElement evalExprOrAnyExpr) void
setExpectedReturnType
(IType expectedReturnType) void
setExpression
(Expression expr) void
setGenRootExprAccess
(boolean bGenRootExprAccess) void
setParsingExecutableProgramStatements
(boolean b) void
setStatement
(Statement stmt) void
setStatementsOnly
(boolean bStatementsOnly) void
setThrowaway
(boolean throwaway) void
void
Methods inherited from class gw.internal.gosu.parser.GosuClass
addBlock, addCapturedSymbol, addDelegateImpls, addInnerClass, addInterface, assignTypeUsesMap, assignTypeVarsFromTypeParams, compareTo, compile, compileDeclarationsIfNeeded, compileDefinitionsIfNeeded, compileDefinitionsIfNeeded, compileHeaderIfNeeded, copyGenericState, copyHierarchyInfo, dontEverCallThis, ensureDefaultConstructor, findProxiedClassInHierarchy, forceTypeInfoInitialization, getAllTypesInHierarchy, getAnonymousInnerClassCount, getArrayComponent, getArrayLength, getArrayType, getBackingClass, getBlock, getBlockCount, getBlocks, getCapturedSymbol, getCapturedSymbols, getClassStatement, getClassStatementWithoutCompile, getCompilationState, getComponentType, getCompoundTypeComponents, getConstructorFunction, getConstructorFunctions, getConstructorStatement, getDefaultConstructor, getDepth, getDisplayName, getEnclosingNonBlockType, getEnclosingType, getEnclosingTypeReference, getEnumConstants, getEnumValue, getEnumValues, getFullDescription, getFunctionalInterface, getFunctionStatement, getGenericType, getGenericTypeVariables, getGosuAnnotations, getId, getInnerClass, getInnerClasses, getInnerClassesMap, getInterfaces, getJavaType, getKnownInnerClassesWithoutCompiling, getLoadedInnerClasses, getLoaderParameterizedTypes, getMemberField, getMemberFieldIndexByName, getMemberFields, getMemberFieldsMap, getMemberFunction, getMemberFunction, getMemberFunctions, getMemberFunctions, getMemberProperties, getMemberProperty, getModifierInfo, getModifiers, getName, getNamespace, getOrCreateTypeReference, getOrCreateTypeReference, getParameterizedType, getParameterizedTypes, getParser, getParseResultsException, getPropertyDeclaration, getRelativeName, getSource, getSourceFileHandle, getSourceFiles, getStaticField, getStaticFields, getStaticFunctions, getStaticProperties, getStaticProperty, getStaticThisSymbol, getSubtypes, getSuperClass, getSupertype, getTypeInfo, getTypeInfoChecksum, getTypeLoader, getTypeParameters, getTypeUsesMap, getTypeVarDefs, getUnimplementedMethods, getUnimplementedMethods, getUnimplementedMethods, hasAncestorBeenUpdated, hasAssertions, hasBackingClass, hasError, hasWarnings, isAbstract, isAccessible, isAnnotation, isArray, isAssignableFrom, isCannotCaptureSymbols, isCompilable, isCompiled, isCompilingDeclarations, isCompilingDefinitions, isCompilingHeader, isCompoundType, isCreateEditorParser, isDeclarationsBypassed, isDeclarationsCompiled, isDefinitionsCompiled, isDiscarded, isEnum, isFinal, isGenericType, isHeaderCompiled, isInnerDeclarationsCompiled, isInterface, isMutable, isObjectMethod, isParameterizedType, isPrimitive, isProxy, isStale, isStatic, isStrictGenerics, isStructure, isSubClass, isTestClass, isValid, makeArrayInstance, makeCopy, markStatic, putClassMembers, putClassMembers, putClassMembers, readResolve, removeBlock, removeInnerClass, resolveRelativeInnerClass, setAnnotations, setArrayComponent, setCannotCaptureSymbols, setCompilingDeclarations, setCompilingDefinitions, setCompilingHeader, setCreateEditorParser, setDeclarationsBypassed, setDeclarationsCompiled, setDefinitionsCompiled, setDiscarded, setEditorParser, setEnclosingType, setEnum, setFullDescription, setGenericTypeVariables, setHasAssertions, setHeaderCompiled, setInnerDeclarationsCompiled, setInterface, setJavaType, setModifierInfo, setNamespace, setParseResultsException, setStructure, setSuperType, setTypeUsesMap, shouldFullyCompileAnnotations, shouldKeepDebugInfo, shouldResolve, syncGenericAndParameterizedClasses, toString, unloadTypeInfo
Methods inherited from class gw.lang.reflect.AbstractType
getLiteralMetaType, getMetaType, getTheRef
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
Methods inherited from interface java.lang.Comparable
compareTo
Methods inherited from interface gw.lang.reflect.ICanBeAnnotation
isAnnotation
Methods inherited from interface gw.lang.reflect.gs.ICompilableType
getBlock, getClassStatement, getParser, getTypeUsesMap, isStatic
Methods inherited from interface gw.internal.gosu.parser.ICompilableTypeInternal
getAnonymousInnerClassCount, getEnclosingType, getMemberFields, getSource, hasAssertions, shouldFullyCompileAnnotations
Methods inherited from interface gw.lang.reflect.IEnumData
getEnumConstants, getEnumValue, getEnumValues
Methods inherited from interface gw.lang.parser.IFileRepositoryBasedType
getJavaName, getSourceFileHandle
Methods inherited from interface gw.lang.reflect.gs.IGosuClass
findProxiedClassInHierarchy, getClassStatementWithoutCompile, getCompilationState, getConstructorStatement, getEnclosingTypeReference, getFunctionStatement, getInnerClass, getInnerClasses, getInnerClassesMap, getJavaType, getKnownInnerClassesWithoutCompiling, getMemberFields, getMemberFieldsMap, getMemberFunctions, getModifierInfo, getParseResultsException, getPropertyDeclaration, getSource, getSubtypes, getTypeInfo, hasBackingClass, hasError, hasWarnings, isCompiled, isCompilingDeclarations, isCompilingDefinitions, isCompilingHeader, isDeclarationsBypassed, isDeclarationsCompiled, isDefinitionsCompiled, isHeaderCompiled, isInnerDeclarationsCompiled, isStructure, isSubClass, isTestClass, setCreateEditorParser, setEnclosingType, setNamespace, shouldKeepDebugInfo
Methods inherited from interface gw.internal.gosu.parser.IGosuClassInternal
addBlock, addCapturedSymbol, addDelegateImpls, addInnerClass, addInterface, assignTypeUsesMap, compileDeclarationsIfNeeded, compileDefinitionsIfNeeded, compileDefinitionsIfNeeded, compileHeaderIfNeeded, copyGenericState, copyHierarchyInfo, dontEverCallThis, ensureDefaultConstructor, forceTypeInfoInitialization, getBlockCount, getBlocks, getCapturedSymbol, getCapturedSymbols, getConstructorFunction, getConstructorFunctions, getDefaultConstructor, getDepth, getEnclosingNonBlockType, getFullDescription, getGosuAnnotations, getMemberField, getMemberFieldIndexByName, getMemberFunction, getMemberFunction, getMemberFunctions, getMemberProperties, getMemberProperty, getParameterizedTypes, getStaticField, getStaticFields, getStaticFunctions, getStaticProperties, getStaticProperty, getStaticThisSymbol, getSuperClass, getTypeInfoChecksum, getTypeLoader, getUnimplementedMethods, getUnimplementedMethods, isAccessible, isCannotCaptureSymbols, isCreateEditorParser, isProxy, isStale, markStatic, putClassMembers, putClassMembers, putClassMembers, removeBlock, removeInnerClass, setAnnotations, setCannotCaptureSymbols, setCompilingDeclarations, setCompilingDefinitions, setCompilingHeader, setDeclarationsBypassed, setDeclarationsCompiled, setDefinitionsCompiled, setEditorParser, setEnum, setFullDescription, setGenericTypeVariables, setHasAssertions, setHeaderCompiled, setInnerDeclarationsCompiled, setInterface, setJavaType, setModifierInfo, setParseResultsException, setStructure, setSuperType, setTypeUsesMap, shouldResolve, syncGenericAndParameterizedClasses
Methods inherited from interface gw.lang.parser.IHasInnerClass
getLoadedInnerClasses, resolveRelativeInnerClass
Methods inherited from interface gw.lang.reflect.IHasJavaClass
getBackingClass
Methods inherited from interface gw.internal.gosu.parser.IParameterizableType
getLoaderParameterizedTypes, isStrictGenerics
Methods inherited from interface gw.lang.reflect.IType
compile, getAllTypesInHierarchy, getArrayComponent, getArrayLength, getArrayType, getComponentType, getCompoundTypeComponents, getDisplayName, getFunctionalInterface, getGenericType, getGenericTypeVariables, getInterfaces, getLiteralMetaType, getMetaType, getModifiers, getName, getNamespace, getParameterizedType, getRelativeName, getSourceFiles, getSupertype, getTypeParameters, isAbstract, isArray, isAssignableFrom, isCompilable, isCompoundType, isDiscarded, isDynamic, isEnum, isFinal, isGenericType, isInterface, isMutable, isParameterizedType, isPrimitive, isValid, makeArrayInstance, readResolve, setArrayComponent, setDiscarded, unloadTypeInfo
-
Field Details
-
_expectedReturnType
-
_bGenRootExprAccess
private boolean _bGenRootExprAccess -
_tokenizerInstructor
-
_anonymous
private boolean _anonymous -
_throwaway
private boolean _throwaway -
_bStatementsOnly
private boolean _bStatementsOnly -
_contextType
-
_ctxInferenceMgr
-
_bParsingExecutableProgramStmts
private boolean _bParsingExecutableProgramStmts -
_allowUses
private boolean _allowUses
-
-
Constructor Details
-
GosuProgram
public GosuProgram(String strNamespace, String strRelativeName, GosuClassTypeLoader classTypeLoader, ISourceFileHandle sourceFile, ITypeUsesMap typeUsesMap, ISymbolTable symTable)
-
-
Method Details
-
addProgramInterfaces
protected void addProgramInterfaces() -
createNewParseInfo
When changing the places from which this method is called run pc's gw.smoketest.pc.job.common.effectivetime.VisibleEffectiveTimeTest cause it will break!- Specified by:
createNewParseInfo
in interfaceIGosuClassInternal
- Overrides:
createNewParseInfo
in classGosuClass
-
getParseInfo
- Specified by:
getParseInfo
in interfaceICompilableTypeInternal
- Specified by:
getParseInfo
in interfaceIGosuClassInternal
- Overrides:
getParseInfo
in classGosuClass
-
getSymbolTable
- Specified by:
getSymbolTable
in interfaceIGosuProgramInternal
-
addProgramEntryPoint
- Specified by:
addProgramEntryPoint
in interfaceIGosuProgramInternal
-
addProgramInstanceMethod
private void addProgramInstanceMethod(ISymbolTable symTable, GosuClassParser parser, IJavaType cls, String strMethod, IType params) -
addExecuteEntryPoint
- Specified by:
addExecuteEntryPoint
in interfaceIGosuProgramInternal
-
addCapturedProgramSymbols
- Specified by:
addCapturedProgramSymbols
in interfaceIGosuProgramInternal
-
isAnonymous
public boolean isAnonymous()- Specified by:
isAnonymous
in interfaceICompilableType
- Overrides:
isAnonymous
in classGosuClass
-
isThrowaway
public boolean isThrowaway()- Specified by:
isThrowaway
in interfaceIGosuProgramInternal
-
setThrowaway
public void setThrowaway(boolean throwaway) - Specified by:
setThrowaway
in interfaceIGosuProgramInternal
-
setAllowUses
public void setAllowUses(boolean b) - Specified by:
setAllowUses
in interfaceIGosuProgramInternal
-
allowsUses
public boolean allowsUses()- Specified by:
allowsUses
in interfaceIGosuProgramInternal
-
setCtxInferenceMgr
- Specified by:
setCtxInferenceMgr
in interfaceIGosuProgramInternal
-
getExternalSymbol
- Specified by:
getExternalSymbol
in interfaceICompilableType
- Overrides:
getExternalSymbol
in classGosuClass
-
setExpression
- Specified by:
setExpression
in interfaceIGosuProgramInternal
-
getExpression
- Specified by:
getExpression
in interfaceIGosuProgram
-
setStatement
- Specified by:
setStatement
in interfaceIGosuProgramInternal
-
getStatement
- Specified by:
getStatement
in interfaceIGosuProgram
-
isExpression
public boolean isExpression()- Specified by:
isExpression
in interfaceIGosuProgram
-
isLhsExpression
public boolean isLhsExpression()- Specified by:
isLhsExpression
in interfaceIGosuProgram
-
getEnclosingEvalExpression
- Specified by:
getEnclosingEvalExpression
in interfaceIGosuProgram
-
setEnclosingEvalExpression
- Specified by:
setEnclosingEvalExpression
in interfaceIGosuProgram
-
evaluate
- Specified by:
evaluate
in interfaceIGosuProgram
-
evaluateRoot
- Specified by:
evaluateRoot
in interfaceIGosuProgram
-
assign
- Specified by:
assign
in interfaceIGosuProgram
-
setGenRootExprAccess
public void setGenRootExprAccess(boolean bGenRootExprAccess) - Specified by:
setGenRootExprAccess
in interfaceIGosuProgramInternal
-
isGenRootExprAccess
public boolean isGenRootExprAccess()- Specified by:
isGenRootExprAccess
in interfaceIGosuProgramInternal
-
getTokenizerInstructor
- Specified by:
getTokenizerInstructor
in interfaceIGosuProgramInternal
-
setTokenizerInstructor
- Specified by:
setTokenizerInstructor
in interfaceIGosuProgramInternal
-
getAdditionalDFSDecls
- Specified by:
getAdditionalDFSDecls
in interfaceIGosuProgramInternal
-
setAdditionalDFSDecls
- Specified by:
setAdditionalDFSDecls
in interfaceIGosuProgramInternal
-
getOrCreateParser
- Overrides:
getOrCreateParser
in classGosuClass
-
getExpectedReturnType
- Specified by:
getExpectedReturnType
in interfaceIGosuProgram
-
setExpectedReturnType
- Specified by:
setExpectedReturnType
in interfaceIGosuProgramInternal
-
getReturnType
- Specified by:
getReturnType
in interfaceIGosuProgram
-
getProgramInstance
- Specified by:
getProgramInstance
in interfaceIGosuProgram
-
unloadBackingClass
public void unloadBackingClass()- Specified by:
unloadBackingClass
in interfaceIGosuClass
- Overrides:
unloadBackingClass
in classGosuClass
-
setAnonymous
public void setAnonymous(boolean b) - Specified by:
setAnonymous
in interfaceIGosuProgramInternal
-
setStatementsOnly
public void setStatementsOnly(boolean bStatementsOnly) - Specified by:
setStatementsOnly
in interfaceIGosuProgramInternal
-
isStatementsOnly
public boolean isStatementsOnly()- Specified by:
isStatementsOnly
in interfaceIGosuProgramInternal
-
createNewInstance
-
runProgram
-
setContextType
- Specified by:
setContextType
in interfaceIGosuProgramInternal
-
getContextType
- Specified by:
getContextType
in interfaceIGosuProgram
-
isParsingExecutableProgramStatements
public boolean isParsingExecutableProgramStatements()- Specified by:
isParsingExecutableProgramStatements
in interfaceIGosuProgramInternal
-
setParsingExecutableProgramStatements
public void setParsingExecutableProgramStatements(boolean b) - Specified by:
setParsingExecutableProgramStatements
in interfaceIGosuProgramInternal
-
getClassType
- Specified by:
getClassType
in interfaceIFileRepositoryBasedType
- Overrides:
getClassType
in classGosuClass
-