Microsoft Foundation Classes (mfc.hlp) (Table of Contents; Topic list)
CTimeSpan::operators <<, >>
CTimeSpan                                   Up Contents Index Back
──Microsoft Foundation Classes──────────────────────────────────────────────
 
  friend CDumpContext& operator <<( CDumpContext& dc, CTimeSpan timeSpan );
  friend CArchive& operator <<( CArchive& ar, CTimeSpan timeSpan );
  friend CArchive& operator >>( CArchive& ar, CTimeSpan& rtimeSpan );
 
  Remarks
 
  The CTimeSpan insert (<<) operator supports diagnostic dumping and
  storing to an archive. The extract (>>) operator supports loading from
  an archive.
 
  When you send a CTimeSpan object to the dump context, the value is
  displayed in a human-readable format that shows days, hours, minutes,
  and seconds.
 
  Example
 
  CTimeSpan ts( 3, 1, 5, 12 ); // 3 days, 1 hour, 5 min, and 12 sec
  #ifdef _DEBUG
  afxDump << ts << "\n";
  #endif
  // prints 'CTimeSpan(3 days, 1 hours, 5 minutes and 12 seconds)'
 
  extern CArchive ar;
  if( ar.IsLoading( ))
    ar >> ts;
  else
    ar << ts;
 
 
                                     -♦-