maj.semant
Class MajCompoundType
java.lang.Object
maj.semant.MajType
maj.semant.MajCompoundType
- All Implemented Interfaces:
- MajMember, MajScope
- public class MajCompoundType
- extends MajType
- implements MajMember, MajScope
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
MajCompoundType
public MajCompoundType()
MajCompoundType
public MajCompoundType(MajScope parentScope,
MajModifiers mods,
java.lang.String name,
MajIdentifier superClass)
toString
public java.lang.String toString()
- Specified by:
toString
in interface MajMember
- Specified by:
toString
in class MajType
getMajType
public java.lang.String getMajType()
- Specified by:
getMajType
in class MajType
getMemberType
public int getMemberType()
- Specified by:
getMemberType
in interface MajMember
getType
public MajType getType()
addMethod
public void addMethod(MajMethod method)
addField
public void addField(MajVariable var)
addInnerClass
public void addInnerClass(MajType newtype)
getTypeEnv
public MajTypeEnv getTypeEnv()
- Specified by:
getTypeEnv
in interface MajScope
getVarEnv
public MajVarEnv getVarEnv()
- Specified by:
getVarEnv
in interface MajScope
getParentScope
public MajScope getParentScope()
- Specified by:
getParentScope
in interface MajScope
setNameSpace
public void setNameSpace(MajNameSpace nameSpace)
- Specified by:
setNameSpace
in interface MajScope
putType
public void putType(java.lang.String tName,
MajType t)
- Specified by:
putType
in interface MajScope
getTypeType
public MajType getTypeType(java.lang.String id)
- Specified by:
getTypeType
in interface MajScope
getTypeType
public MajType getTypeType(MajIdentifier id)
- Specified by:
getTypeType
in interface MajScope
getImports
public MajImport[] getImports()
- Specified by:
getImports
in interface MajScope
addImport
public void addImport(MajImport ip)
- Specified by:
addImport
in interface MajScope
getVariable
public MajVariable getVariable(java.lang.String name)
- Specified by:
getVariable
in interface MajScope
getVariable
public MajVariable getVariable(MajIdentifier id)
- Specified by:
getVariable
in interface MajScope
putVariable
public void putVariable(java.lang.String vName,
MajVariable v)
- Specified by:
putVariable
in interface MajScope
getMethod
public MajMethod getMethod(java.lang.String name)
- Specified by:
getMethod
in interface MajScope
getMethodReturn
public MajType getMethodReturn(java.lang.String name,
MajType[] argTypes)
putMethod
public void putMethod(java.lang.String mName,
MajMethod m)
- Specified by:
putMethod
in interface MajScope
getThisType
public MajType getThisType()
- Specified by:
getThisType
in interface MajScope
getSuperClass
public MajType getSuperClass()
getFieldType
public MajType getFieldType(java.lang.String id)
setModifiers
public void setModifiers(MajModifiers mods)
isEqual
public boolean isEqual(MajType argType)
- Specified by:
isEqual
in class MajType
isSuperOf
public boolean isSuperOf(MajType argType)
- Specified by:
isSuperOf
in class MajType
isPrimitiveType
public boolean isPrimitiveType()
- Specified by:
isPrimitiveType
in class MajType