Main Page | Class Hierarchy | Alphabetical List | Data Structures | File List | Data Fields | Globals

Darray< Logic_t > Class Template Reference

#include <Darray.h>

Collaboration diagram for Darray< Logic_t >:

Collaboration graph
[legend]

Public Types

typedef Logic_t DataType

Public Member Functions

 Darray (const Darray &rhs)
 Darray (const int Size)
Darrayoperator= (const Darray &rhs)
Logic_t & operator[] (const int i)
int Size ()
 ~Darray ()

Private Attributes

Logic_t * _data
int _Size

template<class Logic_t>
class Darray< Logic_t >


Member Typedef Documentation

template<class Logic_t>
typedef Logic_t Darray< Logic_t >.DataType
 

Definition at line 15 of file Darray.h.


Constructor & Destructor Documentation

template<class Logic_t>
Darray< Logic_t >::Darray const int  Size  ) 
 

Definition at line 28 of file Darray.h.

References Darray< Logic_t >._Size.

00029 { 
00030    _Size = Size; 
00031    _data = new Logic_t[ _Size ]; 
00032 }

template<class Logic_t>
Darray< Logic_t >::Darray const Darray< Logic_t > &  rhs  ) 
 

Definition at line 35 of file Darray.h.

References Darray< Logic_t >._data, and Darray< Logic_t >._Size.

00036   : _Size( rhs._Size ) 
00037 {
00038    _data = new Logic_t[ _Size ];
00039    for( int i = 0; i < _Size; i++ ) _data[i] = rhs._data[i];
00040 }

template<class Logic_t>
Darray< Logic_t >::~Darray  ) 
 

Definition at line 43 of file Darray.h.

00044 { 
00045    if ( _data != 0 ) { delete [] _data; _data = 0; } 
00046 }


Member Function Documentation

template<class Logic_t>
Darray< Logic_t > & Darray< Logic_t >::operator= const Darray< Logic_t > &  rhs  ) 
 

Definition at line 49 of file Darray.h.

References Darray< Logic_t >._data, and Darray< Logic_t >._Size.

00049                                                                       {
00050    if ( this != &rhs ) {
00051       _Size = rhs._Size;
00052       for( int i = 0; i <= rhs._Size; i++ ) _data[i] = rhs._data[i];
00053    }
00054    return *this;
00055 }

template<class Logic_t>
Logic_t& Darray< Logic_t >.operator[] const int  i  ) 
 

Definition at line 20 of file Darray.h.

00020 { return _data[i]; }

template<class Logic_t>
int Darray< Logic_t >.Size  ) 
 

Definition at line 21 of file Darray.h.

References Darray< Logic_t >._Size.

Referenced by All(), And(), Any(), MAll(), MAny(), Not(), Or(), and Xor().

00021 { return _Size; }


Field Documentation

template<class Logic_t>
Logic_t* Darray< Logic_t >._data [private]
 

Definition at line 24 of file Darray.h.

Referenced by Darray< Logic_t >.Darray(), and Darray< Logic_t >.operator=().

template<class Logic_t>
int Darray< Logic_t >._Size [private]
 

Definition at line 23 of file Darray.h.

Referenced by Darray< Logic_t >.Darray(), Darray< Logic_t >.operator=(), and Darray< Logic_t >.Size().


The documentation for this class was generated from the following file:
Generated on Mon May 31 21:40:43 2004 for SR2k4 Assembler by doxygen 1.3.6