- A Logic Circuit Simulation Library in C++





lcs::Expression< bits, ONES_COMPLEMENT_EXPR, void, InExprType > Class Template Reference

#include <expression.h>

List of all members.


Detailed Description

template<int bits, typename InExprType>
class lcs::Expression< bits, ONES_COMPLEMENT_EXPR, void, InExprType >

A class whose objects are created as temporary objects which are a result of a one's compliment operation. A user of libLCS will never need to use this class explicitly. Implicitly, this class is used everytime a continuous assignment is requested using the function lcs::Bus::cass.


Public Member Functions

 Expression (const InExprType &e)
 Expression (const Expression< bits, ONES_COMPLEMENT_EXPR, void, InExprType > &e)
const LineState operator[] (int index) const throw (OutOfRangeException<int>)
int width (void) const
void notify (Module *mod)


Constructor & Destructor Documentation

template<int bits, typename InExprType>
lcs::Expression< bits, ONES_COMPLEMENT_EXPR, void, InExprType >::Expression ( const InExprType &  e  ) 

The only usefull constructor. The default constructor is practically useless.

template<int bits, typename InExprType>
lcs::Expression< bits, ONES_COMPLEMENT_EXPR, void, InExprType >::Expression ( const Expression< bits, ONES_COMPLEMENT_EXPR, void, InExprType > &  e  ) 

Copy constructor.


Member Function Documentation

template<int bits, typename InExprType>
void lcs::Expression< bits, ONES_COMPLEMENT_EXPR, void, InExprType >::notify ( Module mod  )  [inline]

This function can be used by a lcs::Module derivative to be notified of line state changes in the busses used in the expression.

template<int bits, typename InExprType>
const LineState lcs::Expression< bits, ONES_COMPLEMENT_EXPR, void, InExprType >::operator[] ( int  index  )  const throw (OutOfRangeException<int>)

Returns the bit state (which is a result of the one's complement operation performed by the expression) at the index specified.

template<int bits, typename InExprType>
int lcs::Expression< bits, ONES_COMPLEMENT_EXPR, void, InExprType >::width ( void   )  const [inline]

Returns the width for which an lcs::Expression object is valid.


Copyright © 2006, 2007 Siva Chandra