Connect++ 0.1
A fast, readable connection prover for first-order logic.
Loading...
Searching...
No Matches
Public Member Functions | Friends | List of all members
PredicateIndex Class Reference

Management of Predicate objects. More...

#include <PredicateIndex.hpp>

Public Member Functions

 PredicateIndex (const PredicateIndex &)=delete
 Copying these is a terrible idea.
 
 PredicateIndex (const PredicateIndex &&)=delete
 
PredicateIndexoperator= (const PredicateIndex &)=delete
 
PredicateIndexoperator= (const PredicateIndex &&)=delete
 
size_t get_num_preds () const
 Basic get method.
 
Predicateadd_predicate (const string &, Arity)
 Self-explanatory.
 
Predicatefind_predicate (const string &, Arity)
 Self-explanatory.
 
Arity find_maximum_arity () const
 Find the largest arity appearing in the index.
 
bool true_false_added () const
 Sometimes $true and $false appear in the TPTP collection. See if you included them during the parsing.
 
Predicateoperator[] (size_t i)
 Access to Predicate pointers, but
don't mess with them!
 

Friends

ostream & operator<< (ostream &, const PredicateIndex &)
 

Detailed Description

Management of Predicate objects.

Note that the unordered_map can use the hash function from FunctionHash.hpp.

As usual only use this to make Predicates. As long as you do so then it takes care of memory allocation and deallocation.

Constructor & Destructor Documentation

◆ PredicateIndex()

PredicateIndex::PredicateIndex ( const PredicateIndex )
delete

Copying these is a terrible idea.

As usual, let the compiler help you out.

Member Function Documentation

◆ add_predicate()

Predicate * PredicateIndex::add_predicate ( const string &  name,
Arity  arity 
)

Self-explanatory.

Parameters
nameName of new Predicate.
arityArity of new Predicate.

◆ find_predicate()

Predicate * PredicateIndex::find_predicate ( const string &  fun_name,
Arity  arity 
)

Self-explanatory.

Parameters
fun_nameName of Predicate.
arityArity of Predicate.

The documentation for this class was generated from the following files: