|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object minijava.typecheck.Type minijava.typecheck.Int
public class Int
This class represents an integer type.
Method Summary | |
---|---|
boolean |
agrees(Type rhs)
Checks whether this Type "agrees" with the given argument. |
static Int |
intType()
|
Methods inherited from class minijava.typecheck.Type |
---|
equals, getTypeName, hashCode, toString |
Methods inherited from class java.lang.Object |
---|
clone, finalize, getClass, notify, notifyAll, wait, wait, wait |
Method Detail |
---|
public static Int intType()
public boolean agrees(Type rhs)
Type
Type
"agrees" with the given argument.
Two types are agreeable if they are equal primitives or, if they
are class types, rhs
is a subclass/subtype of this type.
agrees
in class Type
rhs
- the right hand side in the equivalence test
true
if type(this) == type(rhs)
, or ig
type(this) == supertype(rhs)
, and
false
otherwise
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |