CMS 3D CMS Logo

Public Member Functions | Public Attributes

BlobComplexData Struct Reference

#include <BlobComplex.h>

List of all members.

Public Member Functions

 BlobComplexData ()
void fill (unsigned int &serial)
bool operator!= (const BlobComplexData &rhs) const
bool operator== (const BlobComplexData &rhs) const
void print () const

Public Attributes

unsigned int a
unsigned int b
std::vector< unsigned int > values

Detailed Description

Definition at line 7 of file BlobComplex.h.


Constructor & Destructor Documentation

BlobComplexData::BlobComplexData ( ) [inline]

Definition at line 8 of file BlobComplex.h.

{}

Member Function Documentation

void BlobComplexData::fill ( unsigned int &  serial)

Definition at line 5 of file BlobComplex.cc.

References a, b, i, and values.

{
  a = ++serial;
  b = ++serial;
  for(unsigned int i = 0; i < 10; i++)
    values.push_back(++serial);
}
bool BlobComplexData::operator!= ( const BlobComplexData rhs) const [inline]

Definition at line 13 of file BlobComplex.h.

  { return !(*this == rhs); }
bool BlobComplexData::operator== ( const BlobComplexData rhs) const

Definition at line 23 of file BlobComplex.cc.

References a, b, and values.

{
  if (a != rhs.a) return false;
  if (b != rhs.b) return false;
  if (values.size() != rhs.values.size()) return false;
  std::vector<unsigned int>::const_iterator iter1 = values.begin();
  std::vector<unsigned int>::const_iterator iter2 = rhs.values.begin();
  while(iter1 != values.end())
    if (*iter1++ != *iter2++) return false;
  return true;
}
void BlobComplexData::print ( void  ) const

Definition at line 13 of file BlobComplex.cc.

References a, b, gather_cfg::cout, and values.

{
  std::cout << "        a = " << a << std::endl;
  std::cout << "        b = " << b << std::endl;
  for(std::vector<unsigned int>::const_iterator iter = values.begin();
      iter != values.end(); iter++)
    std::cout << "        value[" << (iter - values.begin()) << "] = "
              << *iter << std::endl;
}

Member Data Documentation

unsigned int BlobComplexData::a

Definition at line 16 of file BlobComplex.h.

Referenced by fill(), operator==(), and print().

unsigned int BlobComplexData::b

Definition at line 16 of file BlobComplex.h.

Referenced by fill(), operator==(), and print().

std::vector<unsigned int> BlobComplexData::values

Definition at line 17 of file BlobComplex.h.

Referenced by fill(), operator==(), and print().