home *** CD-ROM | disk | FTP | other *** search
/ Amiga Format CD 28 / amigaformatcd28.iso / -seriously_amiga- / programming / c / asap / rexxmsg.h < prev    next >
C/C++ Source or Header  |  1998-04-23  |  3KB  |  69 lines

  1. /*****************************************************************************
  2.  *                                                                           *
  3.  * ASAP - Amiga Software Authoring Platform                                  *
  4.  *                                                                           *
  5.  * Written by Laurie Perrin                                                  *
  6.  *                                                                           *
  7.  * ARexxMsg wrapper class                                                    *
  8.  *                                                                           *
  9.  *****************************************************************************/
  10.  
  11. #ifndef ASAP_ARexxMsg_H
  12. #define ASAP_ARexxMsg_H
  13.  
  14. #include <New.h>
  15.  
  16. extern "C"
  17. {
  18.  #include <Proto/RexxSysLib.h>
  19. }
  20.  
  21. class ARexxMsg : public RexxMsg
  22. {
  23.  public:
  24.  inline void ClearRexxMsg(unsigned long count);
  25.  inline static ARexxMsg * CreateRexxMsg(MsgPort * port, UBYTE * extension, UBYTE * host);
  26.  inline void * operator new(size_t, MsgPort * port, UBYTE * extension, UBYTE * host);
  27.  inline void DeleteRexxMsg();
  28.  inline void operator delete(void *);
  29.  inline BOOL FillRexxMsg(unsigned long count, unsigned long mask);
  30.  inline BOOL IsRexxMsg();
  31. };
  32. //----------------------------------------------------------------------------
  33. void ARexxMsg::ClearRexxMsg (unsigned long count)
  34. {
  35.  ::ClearRexxMsg(this, count);
  36. }
  37. //----------------------------------------------------------------------------
  38. ARexxMsg * ARexxMsg::CreateRexxMsg (MsgPort * port, UBYTE * extension, UBYTE * host)
  39. {
  40.  return (ARexxMsg *) ::CreateRexxMsg(port, extension, host);
  41. }
  42. //----------------------------------------------------------------------------
  43. void * ARexxMsg::operator new (size_t, MsgPort * port, UBYTE * extension, UBYTE * host)
  44. {
  45.  return ARexxMsg::CreateRexxMsg(port, extension, host);
  46. }
  47. //----------------------------------------------------------------------------
  48. void ARexxMsg::DeleteRexxMsg ()
  49. {
  50.  ::DeleteRexxMsg(this);
  51. }
  52. //----------------------------------------------------------------------------
  53. void ARexxMsg::operator delete (void *rexxmsg)
  54. {
  55.  ((ARexxMsg *) rexxmsg)->DeleteRexxMsg();
  56. }
  57. //----------------------------------------------------------------------------
  58. BOOL ARexxMsg::FillRexxMsg (unsigned long count, unsigned long mask)
  59. {
  60.  return ::FillRexxMsg(this, count, mask);
  61. }
  62. //----------------------------------------------------------------------------
  63. BOOL ARexxMsg::IsRexxMsg ()
  64. {
  65.  return ::IsRexxMsg(this);
  66. }
  67.  
  68. #endif
  69.