EMAN2
Public Member Functions | Private Attributes
Maxclique::ColorClass Class Reference

List of all members.

Public Member Functions

 ColorClass ()
 ColorClass (const int sz)
 ~ColorClass ()
void init (const int sz)
void push (const int ii)
void pop ()
void rewind ()
int size () const
int & at (const int ii) const
ColorClassoperator= (const ColorClass &dh)

Private Attributes

int * i
int sz

Detailed Description

Definition at line 71 of file mcqd.h.


Constructor & Destructor Documentation

Maxclique::ColorClass::ColorClass ( ) [inline]

Definition at line 83 of file mcqd.h.

: sz(0), i(0) {}
Maxclique::ColorClass::ColorClass ( const int  sz) [inline]

Definition at line 84 of file mcqd.h.

: sz(sz), i(0) { init(sz); }
Maxclique::ColorClass::~ColorClass ( ) [inline]

Definition at line 85 of file mcqd.h.

                  { if (i) delete [] i;
    }

Member Function Documentation

int& Maxclique::ColorClass::at ( const int  ii) const [inline]

Definition at line 92 of file mcqd.h.

Referenced by Maxclique::_mcq(), and Maxclique::cut1().

{ return i[ii]; }
void Maxclique::ColorClass::init ( const int  sz) [inline]

Definition at line 87 of file mcqd.h.

{ i = new int[sz]; rewind(); }
ColorClass& Maxclique::ColorClass::operator= ( const ColorClass dh) [inline]

Definition at line 93 of file mcqd.h.

References i, and sz.

                                                {
      for (int j = 0; j < dh.sz; j++) i[j] = dh.i[j];
      sz = dh.sz;
      return *this;
    }
void Maxclique::ColorClass::pop ( ) [inline]

Definition at line 89 of file mcqd.h.

Referenced by Maxclique::expand(), and Maxclique::expand_dyn().

{ sz--; };
void Maxclique::ColorClass::push ( const int  ii) [inline]

Definition at line 88 of file mcqd.h.

Referenced by Maxclique::color_sort(), Maxclique::expand(), and Maxclique::expand_dyn().

{ i[sz++] = ii; };
void Maxclique::ColorClass::rewind ( ) [inline]

Definition at line 90 of file mcqd.h.

Referenced by Maxclique::color_sort().

{ sz = 0; };
int Maxclique::ColorClass::size ( ) const [inline]

Member Data Documentation

int* Maxclique::ColorClass::i [private]

Definition at line 72 of file mcqd.h.

Referenced by operator=().

Definition at line 73 of file mcqd.h.

Referenced by operator=().


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