home *** CD-ROM | disk | FTP | other *** search
/ Magazyn Internet 2000 May / MICD_2000_05.iso / CBuilder5 / INSTALL / DATA1.CAB / Program_Built_Files / Include / chanstr.h < prev    next >
C/C++ Source or Header  |  2000-02-01  |  3KB  |  97 lines

  1. /***********************************************************************
  2. **          C H A N S T R . H                                            *
  3. **                                                                     *
  4. ************************************************************************
  5. ** Copyright (C) 1996 - 1999 Microsoft Corporation                         *
  6. **                 All Rights Reserved                                 *
  7. ************************************************************************/
  8. /*
  9.         CHANSTR.H
  10.  
  11.         ChannelStream record object class definitions for Microsoft Guide
  12. */
  13.  
  14.  
  15. #ifndef _CHANSTR_H_
  16. #pragma option push -b -a8 -pc -A- /*P_O_Push*/
  17. #define _CHANSTR_H_
  18.  
  19.  
  20. #include "dbsets.h"
  21.  
  22.  
  23. /*
  24.  
  25. ChannelStream objects are constructed from database records of the ChannelStream table.
  26.  
  27. The CChannelStreamRecordset class is used to select and create CChannelStream objects
  28. from the ChannelStream table via functions in the CDatabaseRecordset parent class.
  29.  
  30. */
  31.  
  32.  
  33. class  COMMMSTVEXPORT CChannelStreamRecordset : public CDatabaseRecordset
  34. {
  35. // This class provides ChannelStream recordset manipulation via parent functions
  36.  
  37. virtual CString GetTableName( VOID);
  38.  
  39. virtual BOOL    SetRecordsetObject( VOID* cRecordsetObject);
  40.  
  41. public:
  42. virtual VOID*   GetRecordsetObject( VOID);
  43. virtual BOOLEAN Seek(LPCTSTR lpszComparison, CObject &coo);
  44. };
  45.  
  46.  
  47. class COMMMSTVEXPORT CChannelStream : public CObject
  48. {
  49.     friend class CChannelStreamRecordset; // generates the CChannelStream record object
  50.  
  51. private:
  52.  
  53.     LONG        m_lChannelID;
  54.     LONG        m_lStreamTypeID;
  55.     LONG        m_lSubChannel;
  56.     CString        m_cszName;
  57.  
  58. public:
  59.  
  60.     CChannelStream(LONG lChannelID = 0,
  61.                     LONG lStreamTypeID = 0,
  62.                     LONG lSubChannel = 0,
  63.                     CString cszName = "") :
  64.                     m_lChannelID(lChannelID),
  65.                     m_lStreamTypeID(lStreamTypeID),
  66.                     m_lSubChannel(lSubChannel),
  67.                     m_cszName(cszName) { }
  68.  
  69.     ~CChannelStream(VOID) { }
  70.  
  71.     VOID    SetChannelID( LONG lChannelID) { m_lChannelID = lChannelID; }
  72.     VOID    SetStreamTypeID( LONG lStreamTypeID) { m_lStreamTypeID = lStreamTypeID; }
  73.     VOID    SetSubChannel( LONG lSubChannel) { m_lSubChannel = lSubChannel; }
  74.     VOID    SetName( CString cszName) { m_cszName = cszName; }
  75.  
  76.     LONG            ChannelID() { return m_lChannelID; }
  77.     LONG            StreamTypeID() { return m_lStreamTypeID; }
  78.     LONG            SubChannel() { return m_lSubChannel; }
  79.     CString         Name() { return m_cszName; }
  80. };
  81.  
  82. // Table: ChannelStream
  83.  
  84. #define TBL_ChannelStream  _T("[Channel Stream]")
  85.  
  86. //      Field:                          Name                        Type        Size
  87.  
  88. #define FLD_ChannelStream_ChannelID        _T("CSR Channel ID")            // Long      4
  89. #define FLD_ChannelStream_StreamTypeID    _T("CSR Stream Type ID")        // Long      4
  90. #define FLD_ChannelStream_SubChannel    _T("CSR SubChannel")            // Long     4
  91. #define FLD_ChannelStream_Name            _T("CSR Name")                  // Memo     255
  92.  
  93. #pragma option pop /*P_O_Pop*/
  94. #endif
  95.  
  96.  
  97.