cvc4-1.4
|
Class encapsulating the datatype type. More...
#include <type.h>
Public Member Functions | |
DatatypeType (const Type &type=Type()) throw (IllegalArgumentException) | |
Construct from the base type. | |
const Datatype & | getDatatype () const |
Get the underlying datatype. | |
bool | isParametric () const |
Is this datatype parametric? | |
Expr | getConstructor (std::string name) const |
Get the constructor operator associated to the given constructor name in this datatype. | |
bool | isInstantiated () const |
Has this datatype been fully instantiated ? | |
bool | isParameterInstantiated (unsigned n) const |
Has this datatype been instantiated for parameter N ? | |
std::vector< Type > | getParamTypes () const |
Get the parameter types. | |
size_t | getArity () const |
Get the arity of the datatype constructor. | |
DatatypeType | instantiate (const std::vector< Type > ¶ms) const |
Instantiate a datatype using this datatype constructor. | |
bool | isNull () const |
Check whether this is a null type. | |
Cardinality | getCardinality () const |
Return the cardinality of this type. | |
bool | isWellFounded () const |
Is this a well-founded type? | |
Expr | mkGroundTerm () const |
Construct and return a ground term for this Type. | |
bool | isSubtypeOf (Type t) const |
Is this type a subtype of the given type? | |
bool | isComparableTo (Type t) const |
Is this type comparable to the given type (i.e., do they share a common ancestor in the subtype tree)? | |
Type | getBaseType () const |
Get the most general base type of this type. | |
Type | substitute (const Type &type, const Type &replacement) const |
Substitution of Types. | |
Type | substitute (const std::vector< Type > &types, const std::vector< Type > &replacements) const |
Simultaneous substitution of Types. | |
ExprManager * | getExprManager () const |
Get this type's ExprManager. | |
Type | exportTo (ExprManager *exprManager, ExprManagerMapCollection &vmap) const |
Exports this type into a different ExprManager. | |
bool | operator== (const Type &t) const |
Comparison for structural equality. | |
bool | operator!= (const Type &t) const |
Comparison for structural disequality. | |
bool | operator< (const Type &t) const |
An ordering on Types so they can be stored in maps, etc. | |
bool | operator<= (const Type &t) const |
An ordering on Types so they can be stored in maps, etc. | |
bool | operator> (const Type &t) const |
An ordering on Types so they can be stored in maps, etc. | |
bool | operator>= (const Type &t) const |
An ordering on Types so they can be stored in maps, etc. | |
bool | isBoolean () const |
Is this the Boolean type? | |
bool | isInteger () const |
Is this the integer type? | |
bool | isReal () const |
Is this the real type? | |
bool | isString () const |
Is this the string type? | |
bool | isBitVector () const |
Is this the bit-vector type? | |
bool | isFunction () const |
Is this a function type? | |
bool | isPredicate () const |
Is this a predicate type, i.e. | |
bool | isTuple () const |
Is this a tuple type? | |
bool | isRecord () const |
Is this a record type? | |
bool | isSExpr () const |
Is this a symbolic expression type? | |
bool | isArray () const |
Is this an array type? | |
bool | isSet () const |
Is this a Set type? | |
bool | isDatatype () const |
Is this a datatype type? | |
bool | isConstructor () const |
Is this a constructor type? | |
bool | isSelector () const |
Is this a selector type? | |
bool | isTester () const |
Is this a tester type? | |
bool | isSort () const |
Is this a sort kind? | |
bool | isSortConstructor () const |
Is this a sort constructor kind? | |
bool | isSubrange () const |
Is this a predicate subtype? | |
void | toStream (std::ostream &out) const |
Outputs a string representation of this type to the stream. | |
std::string | toString () const |
Constructs a string representation of this type. | |
Protected Member Functions | |
Type | makeType (const TypeNode &typeNode) const |
Construct a new type given the typeNode, for internal use only. | |
Static Protected Member Functions | |
static TypeNode * | getTypeNode (const Type &t) throw () |
Accessor for derived classes. | |
Protected Attributes | |
TypeNode * | d_typeNode |
The internal expression representation. | |
NodeManager * | d_nodeManager |
The responsible expression manager. | |
CVC4::DatatypeType::DatatypeType | ( | const Type & | type = Type() | ) | ||
throw | ( | IllegalArgumentException ) |
Construct from the base type.
|
inherited |
Exports this type into a different ExprManager.
Referenced by CVC4::Command::ExportTransformer::operator()().
size_t CVC4::DatatypeType::getArity | ( | ) | const |
Get the arity of the datatype constructor.
|
inherited |
Get the most general base type of this type.
|
inherited |
Return the cardinality of this type.
Expr CVC4::DatatypeType::getConstructor | ( | std::string | name | ) | const |
Get the constructor operator associated to the given constructor name in this datatype.
const Datatype & CVC4::DatatypeType::getDatatype | ( | ) | const |
Get the underlying datatype.
|
inherited |
Get this type's ExprManager.
std::vector< Type > CVC4::DatatypeType::getParamTypes | ( | ) | const |
Get the parameter types.
DatatypeType CVC4::DatatypeType::instantiate | ( | const std::vector< Type > & | params | ) | const |
Instantiate a datatype using this datatype constructor.
|
inherited |
Is this an array type?
|
inherited |
Is this the bit-vector type?
|
inherited |
Is this the Boolean type?
|
inherited |
Is this type comparable to the given type (i.e., do they share a common ancestor in the subtype tree)?
|
inherited |
Is this a constructor type?
|
inherited |
Is this a datatype type?
|
inherited |
Is this a function type?
bool CVC4::DatatypeType::isInstantiated | ( | ) | const |
Has this datatype been fully instantiated ?
|
inherited |
Is this the integer type?
|
inherited |
Check whether this is a null type.
bool CVC4::DatatypeType::isParameterInstantiated | ( | unsigned | n | ) | const |
Has this datatype been instantiated for parameter N ?
bool CVC4::DatatypeType::isParametric | ( | ) | const |
Is this datatype parametric?
|
inherited |
Is this a predicate type, i.e.
if it's a function type mapping to Boolean. All predicate types are also function types.
|
inherited |
Is this the real type?
|
inherited |
Is this a record type?
|
inherited |
Is this a selector type?
|
inherited |
Is this a Set type?
|
inherited |
Is this a symbolic expression type?
|
inherited |
Is this a sort kind?
|
inherited |
Is this a sort constructor kind?
|
inherited |
Is this the string type?
|
inherited |
Is this a predicate subtype?
|
inherited |
Is this type a subtype of the given type?
|
inherited |
Is this a tester type?
|
inherited |
Is this a tuple type?
|
inherited |
Is this a well-founded type?
Construct a new type given the typeNode, for internal use only.
typeNode | the TypeNode to use |
|
inherited |
Construct and return a ground term for this Type.
Throws an exception if this type is not well-founded.
|
inherited |
Comparison for structural disequality.
t | the type to compare to |
|
inherited |
An ordering on Types so they can be stored in maps, etc.
|
inherited |
An ordering on Types so they can be stored in maps, etc.
|
inherited |
Comparison for structural equality.
t | the type to compare to |
|
inherited |
An ordering on Types so they can be stored in maps, etc.
|
inherited |
An ordering on Types so they can be stored in maps, etc.
|
inherited |
Simultaneous substitution of Types.
Substitution of Types.
|
inherited |
Outputs a string representation of this type to the stream.
out | the stream to output to |
|
inherited |
Constructs a string representation of this type.
|
protectedinherited |
|
protectedinherited |