class HMdcTBArray

_HADES_CLASS_DESCRIPTION

 HMdcTBArray

  LookupTable and some useful functions for working
  with an array of two bits.
  For MDC it can be used for keeping information about
  number of cell times:
 only time1 - 1
 only time2 - 2
 time1 & time2 - 3

   void clear(UChar_t *pF, UChar_t *pL);
   void set(UChar_t *pF, Int_t pos, UChar_t cont);
   Int_t get(UChar_t *pF, Int_t pos);
   void unset(UChar_t *pF, Int_t pos, UChar_t cont);
   Int_t getNSet(UChar_t *pF, UChar_t *pL);
   Int_t position(UChar_t *pF, UChar_t *pL, Int_t idx);
        = content of two bits or =-1
   Int_t first(UChar_t *pF, UChar_t *pL);
        = content of two bits or =-1
   Int_t last(UChar_t *pF, UChar_t *pL);
        = content of two bits or =-1
   Int_t next(UChar_t *pF, UChar_t *pL, Int_t prPos);
        = content of two bits or =-1
   Int_t previous(UChar_t *pF, UChar_t *pL, Int_t prPos);
        = content of two bits or =-1
   void shiftRight(UChar_t *pF, UChar_t *pL, UChar_t *pS);
   void shiftLeft(UChar_t *pF, UChar_t *pL, UChar_t *pS);
   Int_t compare(UChar_t *pF1, UChar_t *pF2, Int_t nBytes);

 pF - pointer to the first byte of bytes array
 pL - pointer to the last byte of bytes array
 cont - content of two bits, can be = 0,1,2,3
 pos - position of element in two bit array (for examp. - num. cell MDC)
 idx - index of element
 prPos - position of the element, used for geting position of the
         next or previous position aftre or before pos. prPos
 pS - pointer to the byte which mast be moved to *pL (shift to right)
                                        or to *pT (shift to left)


Function Members (Methods)

public:
HMdcTBArray(const HMdcTBArray&)
static Int_tandArr(const UChar_t* pF1, const UChar_t* pF2, Int_t nBytes, UChar_t* pOut)
static Int_tandArrAndUnset(UChar_t* pNoId, const UChar_t* pEx, Int_t nBytes, UChar_t* pIdnt)
static TClass*Class()
static voidclear(UChar_t* pF, UChar_t* pL)
static Int_tcompare(const UChar_t* pF1, const UChar_t* pF2, Int_t nBytes)
static Int_tfirst(const UChar_t* pF, const UChar_t* pL)
static UChar_tget(const UChar_t* pF, Int_t pos)
static Int_tgetNSet(const UChar_t* pF, const UChar_t* pL)
virtual TClass*IsA() const
static Bool_tisIdenBits(const UChar_t* pF1, const UChar_t* pF2, Int_t nBytes)
static Int_tlast(const UChar_t* pF, const UChar_t* pL)
static Int_tnext(const UChar_t* pF, const UChar_t* pL, Int_t prPos)
static UChar_tnext2Bits(const UChar_t* pF, const UChar_t* pL, Int_t& pos)
HMdcTBArray&operator=(const HMdcTBArray&)
static Int_tposition(const UChar_t* pF, const UChar_t* pL, Int_t idx)
static Int_tprevious(const UChar_t* pF, const UChar_t* pL, Int_t prPos)
static voidset(UChar_t* pF, Int_t pos, UChar_t cont)
static voidshiftLeft(UChar_t* pT, UChar_t* pL, UChar_t* pS)
static voidshiftRight(UChar_t* pF, UChar_t* pL, UChar_t* pS)
virtual voidShowMembers(TMemberInspector& insp, char* parent)
virtual voidStreamer(TBuffer& b)
voidStreamerNVirtual(TBuffer& b)
static voidunset(UChar_t* pF, Int_t pos, UChar_t cont)
static Int_txorArr(const UChar_t* pF1, const UChar_t* pF2, Int_t nBytes, UChar_t* pOut)
private:
HMdcTBArray()
(unknown)()

Data Members

protected:
static UChar_tnTBitLookUp[256]
static UChar_tnextTBit[4]
static UChar_tpTBitLookUp[4][256]
static UChar_tprevTBit[4]

Class Charts

Inheritance Inherited Members Includes Libraries
Class Charts

Function documentation

Int_t next(const UChar_t* pF, const UChar_t* pL, Int_t prPos)
 prPos <0 eq. first
 return -1 if next is absent
UChar_t next2Bits(const UChar_t* pF, const UChar_t* pL, Int_t& pos)
 prPos <0 eq. first
 return 1 for time1, 2 for time2 or 3 for time1 and time2
 return 0 if next is absent
Int_t previous(const UChar_t* pF, const UChar_t* pL, Int_t prPos)
 prPos >size eq. last
 return -1 if previous is absent
void clear(UChar_t* pF, UChar_t* pL)
 Inlines HMdcTBarray
Int_t getNSet(const UChar_t* pF, const UChar_t* pL)
void set(UChar_t* pF, Int_t pos, UChar_t cont)
void unset(UChar_t* pF, Int_t pos, UChar_t cont)
Int_t position(const UChar_t* pF, const UChar_t* pL, Int_t idx)
 return: >=0 - ok.!;
Int_t first(const UChar_t* pF, const UChar_t* pL)
 return: -1 - num.cells=0
Int_t last(const UChar_t* pF, const UChar_t* pL)
 return: >=0 - ok.!; -2 - num. of cells =0
void shiftRight(UChar_t* pF, UChar_t* pL, UChar_t* pS)
 pF - pointer to first element, pL - pointer to last el.
 pS - pointer to element which must be moved to *pL ((pL-pS) - shift)
void shiftLeft(UChar_t* pT, UChar_t* pL, UChar_t* pS)
 pT - pointer to the first elelement, pL - pointer to last el.
 pS - pointer to element which must be moved to *pT
UChar_t get(const UChar_t* pF, Int_t pos)
 Returns 1 for time1, 2 for time2 and 3 for time1 and time2 in cell
Int_t compare(const UChar_t* pF1, const UChar_t* pF2, Int_t nBytes)
Bool_t isIdenBits(const UChar_t* pF1, const UChar_t* pF2, Int_t nBytes)
return kTRUE if at list one the same bit is setted on both arrays
Int_t andArr(const UChar_t* pF1, const UChar_t* pF2, Int_t nBytes, UChar_t* pOut)
 Function produce list of identical for pF1 & ppF2 bits - pOut
 return number of the same cells(!)
Int_t andArrAndUnset(UChar_t* pNoId, const UChar_t* pEx, Int_t nBytes, UChar_t* pIdnt)
 Function produce list of identical for pNoId & ppEx bits - pIdnt
 and unset identical bits in pNoId
 return number of the same cells(!)
Int_t xorArr(const UChar_t* pF1, const UChar_t* pF2, Int_t nBytes, UChar_t* pOut)
 Function produce list of nonidentical for pF1 & ppF2 bits - pOut
 return number of the same cells(!)
HMdcTBArray(const HMdcTBArray& )
{}

Last change: Sat May 22 13:03:39 2010
Last generated: 2010-05-22 13:03

This page has been automatically generated. If you have any comments or suggestions about the page layout send a mail to ROOT support, or contact the developers with any questions or problems regarding ROOT.