Main Page | Namespace List | Class Hierarchy | Class List | File List | Namespace Members | Class Members

spot::ltl::binop Class Reference

Binary operator. More...

#include <binop.hh>

Inheritance diagram for spot::ltl::binop:

Inheritance graph
[legend]
Collaboration diagram for spot::ltl::binop:

Collaboration graph
[legend]
List of all members.

Public Types

enum  type {
  Xor, Implies, Equiv, U,
  R
}

Public Member Functions

virtual void accept (visitor &v)
 Entry point for vspot::ltl::visitor instances.

virtual void accept (const_visitor &v) const
 Entry point for vspot::ltl::const_visitor instances.

const formulafirst () const
 Get the first operand.

formulafirst ()
 Get the first operand.

const formulasecond () const
 Get the second operand.

formulasecond ()
 Get the second operand.

type op () const
 Get the type of this operator.

const char * op_name () const
 Get the type of this operator, as a string.

formularef ()
 clone this node


Static Public Member Functions

binopinstance (type op, formula *first, formula *second)
unsigned instance_count ()
 Number of instantiated binary operators. For debugging.

void unref (formula *f)
 release this node


Protected Types

typedef std::pair< formula *,
formula * > 
pairf
typedef std::pair< type, pairfpair
typedef std::map< pair, formula * > map

Protected Member Functions

 binop (type op, formula *first, formula *second)
virtual ~binop ()
void ref_ ()
 increment reference counter if any

bool unref_ ()
 decrement reference counter if any, return true when the instance must be deleted (usually when the counter hits 0).

unsigned ref_count_ ()
 Number of references to this formula.


Static Protected Attributes

map instances

Private Attributes

type op_
formulafirst_
formulasecond_

Detailed Description

Binary operator.


Member Typedef Documentation

typedef std::map<pair, formula*> spot::ltl::binop::map [protected]
 

typedef std::pair<type, pairf> spot::ltl::binop::pair [protected]
 

typedef std::pair<formula*, formula*> spot::ltl::binop::pairf [protected]
 


Member Enumeration Documentation

enum spot::ltl::binop::type
 

Different kinds of binary opertaors

And and Or are not here. Because they are often nested we represent them as multops.

Enumeration values:
Xor 
Implies 
Equiv 
U 
R 


Constructor & Destructor Documentation

spot::ltl::binop::binop type  op,
formula first,
formula second
[protected]
 

virtual spot::ltl::binop::~binop  )  [protected, virtual]
 


Member Function Documentation

virtual void spot::ltl::binop::accept const_visitor v  )  const [virtual]
 

Entry point for vspot::ltl::const_visitor instances.

Implements spot::ltl::formula.

virtual void spot::ltl::binop::accept visitor v  )  [virtual]
 

Entry point for vspot::ltl::visitor instances.

Implements spot::ltl::formula.

formula* spot::ltl::binop::first  ) 
 

Get the first operand.

const formula* spot::ltl::binop::first  )  const
 

Get the first operand.

binop* spot::ltl::binop::instance type  op,
formula first,
formula second
[static]
 

Build an unary operator with operation op and children first and second.

unsigned spot::ltl::binop::instance_count  )  [static]
 

Number of instantiated binary operators. For debugging.

type spot::ltl::binop::op  )  const
 

Get the type of this operator.

const char* spot::ltl::binop::op_name  )  const
 

Get the type of this operator, as a string.

formula* spot::ltl::formula::ref  )  [inherited]
 

clone this node

This increments the reference counter of this node (if one is used). You should almost never use this method directly as it doesn't touch the children. If you want to clone a whole formula, use spot::ltl::clone() instead.

void spot::ltl::ref_formula::ref_  )  [protected, virtual, inherited]
 

increment reference counter if any

Reimplemented from spot::ltl::formula.

unsigned spot::ltl::ref_formula::ref_count_  )  [protected, inherited]
 

Number of references to this formula.

formula* spot::ltl::binop::second  ) 
 

Get the second operand.

const formula* spot::ltl::binop::second  )  const
 

Get the second operand.

void spot::ltl::formula::unref formula f  )  [static, inherited]
 

release this node

This decrements the reference counter of this node (if one is used) and can free the object. You should almost never use this method directly as it doesn't touch the children. If you want to release a whole formula, use spot::ltl::destroy() instead.

bool spot::ltl::ref_formula::unref_  )  [protected, virtual, inherited]
 

decrement reference counter if any, return true when the instance must be deleted (usually when the counter hits 0).

Reimplemented from spot::ltl::formula.


Member Data Documentation

formula* spot::ltl::binop::first_ [private]
 

map spot::ltl::binop::instances [static, protected]
 

type spot::ltl::binop::op_ [private]
 

formula* spot::ltl::binop::second_ [private]
 


The documentation for this class was generated from the following file:
Generated on Tue Jun 29 17:02:18 2004 for spot by doxygen 1.3.7