CMS 3D CMS Logo

Public Member Functions

DCCTBDataFieldComparator Class Reference

#include <DCCDataMapper.h>

List of all members.

Public Member Functions

bool operator() (DCCTBDataField *d1, DCCTBDataField *d2)

Detailed Description

Definition at line 60 of file DCCDataMapper.h.


Member Function Documentation

bool DCCTBDataFieldComparator::operator() ( DCCTBDataField d1,
DCCTBDataField d2 
) [inline]

Overloads operator() returning true if DCCDataField 1 comes first then DCCDataField 2 in the DCC data block

Definition at line 67 of file DCCDataMapper.h.

References DCCTBDataField::bitPosition(), relativeConstraints::value, and DCCTBDataField::wordPosition().

                                                          {
    bool value(false);
    
    if (d1->wordPosition() < d2->wordPosition()){ 
      value=true;
    }
    else if(d1->wordPosition() == d2->wordPosition()){ 
      if(d1->bitPosition() > d2->bitPosition()) {
        value=true;
      } 
    }
    
    return value;  
  }