|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectorg.norecess.citkit.types.NameType
public class NameType
Data type for a named type.
| Constructor Summary | |
|---|---|
NameType(ISymbol symbol)
|
|
NameType(ISymbol symbol,
HobbesType binding)
|
|
NameType(java.lang.String name)
|
|
NameType(java.lang.String name,
HobbesType binding)
|
|
| Method Summary | ||
|---|---|---|
|
accept(TypeVisitor<T> visitor)
|
|
HobbesType |
actual()
Returns the actual data type this named type represents. |
|
void |
bind(HobbesType type)
Binds the named type to another type. |
|
boolean |
equals(java.lang.Object o)
|
|
HobbesType |
getBinding()
Returns the binding of this named type. |
|
ISymbol |
getSymbol()
|
|
int |
hashCode()
|
|
boolean |
isBound()
Returns a boolean regarding the boundness of this named type. |
|
java.lang.String |
toShortString()
|
|
java.lang.String |
toString()
|
|
| Methods inherited from class java.lang.Object |
|---|
clone, finalize, getClass, notify, notifyAll, wait, wait, wait |
| Constructor Detail |
|---|
public NameType(ISymbol symbol)
public NameType(ISymbol symbol,
HobbesType binding)
public NameType(java.lang.String name)
public NameType(java.lang.String name,
HobbesType binding)
| Method Detail |
|---|
public ISymbol getSymbol()
getSymbol in interface INameTypepublic HobbesType actual()
IntegerTypeor
RecordType).
actual in interface HobbesTypejava.lang.NullPointerException - is the named type is unbound.bind(HobbesType),
getBinding()public void bind(HobbesType type)
actual()will recursively
call itself on this binding until it reaches a basic type.
bind in interface INameTypetype - the real type of this named type.actual(),
getBinding()public HobbesType getBinding()
actual(), this
method returns just the binding of this named type; it does not follow
any chain of bindings to find a basic type.
getBinding in interface INameTypeactual(),
bind(HobbesType)public boolean isBound()
isBound in interface HobbesTypetrue if this named type is bound, false
otherwise.public <T> T accept(TypeVisitor<T> visitor)
accept in interface HobbesTypepublic boolean equals(java.lang.Object o)
equals in class java.lang.Objectpublic int hashCode()
hashCode in class java.lang.Objectpublic java.lang.String toString()
toString in class java.lang.Objectpublic java.lang.String toShortString()
toShortString in interface HobbesType
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||