orc.type
Class Tycon

java.lang.Object
  extended by orc.type.Type
      extended by orc.type.Tycon
Direct Known Subclasses:
Datatype, ImmutableContainerType, MutableContainerType

public abstract class Tycon
extends Type

Root class for all type constructors. Currently, the instance method for a tycon simply creates a TypeApplication type of that tycon to the instance parameters. The TypeApplication class handles subtype, meet, and join for tycons. It is assumed that all children of Tycon will implement variances() such that its size() > 0, but there is no way to enforce this condition in Java.

Author:
dkitchin

Field Summary
 
Fields inherited from class orc.type.Type
BLANK, BOOLEAN, BOT, INTEGER, LET, NUMBER, STRING, TOP
 
Constructor Summary
Tycon()
           
 
Method Summary
 Type instance(java.util.List<Type> params)
           
 Type instance(Type param)
           
 
Methods inherited from class orc.type.Type
addConstraints, assertSubtype, call, call, closed, demote, equal, findVariance, freeVars, isBot, isTop, join, makeCallableInstance, meet, promote, subst, substAll, subtype, supertype, toString, unwrapAs, variances
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Constructor Detail

Tycon

public Tycon()
Method Detail

instance

public Type instance(java.util.List<Type> params)
              throws TypeException
Throws:
TypeException

instance

public Type instance(Type param)
              throws TypeException
Throws:
TypeException