Set atom type and value to that of another, operand atom.

Return TypeFunction nameArguments
hzAtom&hzAtom::operator=(hzAtom&,)

Declared in file: hzDatabase.h
Defined in file : hzAtom.cpp

Function Logic:

0:START 1:items 2:unknown 3:unknown 4:m_Data items m_eType m_eStatus 5:Return *this 6:op.m_eType 7:BASETYPE_DOMAIN 8:items

Function body:

hzAtom& hzAtom::operator= (hzAtom& op)
{
   //  Set atom type and value to that of another, operand atom.
   //  
   //  Argument: a The operand atom
   //  Returns: Reference to this atom
   _hzfunc("hzAtom::operator=(hzAtom)") ;
   Clear() ;
   if (op.m_eType == BASETYPE_DIGEST)
   {
       if (op.m_Data.m_pVoid)
       {
           m_Data.m_pVoid = new uchar[16];
           memcpy(m_Data.m_pVoid, op.m_Data.m_pVoid, sizeof(hzMD5)) ;
           m_eType = op.m_eType ;
           m_eStatus = op.m_eStatus ;
       }
       return *this ;
   }
   switch  (op.m_eType)
   {
   case BASETYPE_DOMAIN:   operator=(op.Domain()) ;    break ;
   case BASETYPE_EMADDR:   operator=(op.Emaddr()) ;    break ;
   case BASETYPE_URL:      operator=(op.Url()) ;       break ;
   default:
       m_eType = op.m_eType ;
       m_eStatus = op.m_eStatus ;
       //  m_bCast = 0 ;
       m_Data = op.m_Data ;
   }
   return *this ;
}