home *** CD-ROM | disk | FTP | other *** search
/ Network Support Encyclopedia 96-1 / novell-nsepro-1996-1-cd2.iso / download / netware / dn511.exe / DSCONNBU.H < prev    next >
C/C++ Source or Header  |  1995-01-09  |  3KB  |  76 lines

  1. /*
  2. **    Copyright ⌐ 1994 Novell, Inc.  All rights reserved.
  3. **
  4. **    Permission is granted to the recipient of this work ("you") to use,
  5. **    reproduce and distribute Novell's original publication of the work free
  6. **    of charge provided that you reproduce the work in its entirety and
  7. **    include all Novell copyright notices as they originally appear.
  8. **
  9. **    Novell grants you permission to modify and distribute copies of this
  10. **    work including any portion of this work (a "modified work") provided
  11. **    that you include prominent notification of such modification along with
  12. **    the date of modification on a modified work; distribute or publish a
  13. **    modified work to third parties under the same conditions and granting
  14. **    the same rights as are extended to you by Novell under this under
  15. **    permission notice; and provided that you include a copy of Novell's
  16. **    original publication of the work along with any copy of a modified
  17. **    work.
  18. **
  19. **    NOVELL MAKES NO WARRANTY, REPRESENTATION OR PROMISE THAT THIS WORK OR A
  20. **    MODIFIED WORK WILL SATISFY YOUR REQUIREMENTS OR THAT THIS WORK OR A
  21. **    MODIFIED WORK IS WITHOUT DEFECT OR ERROR.  NOVELL DISCLAIMS AND
  22. **    EXCLUDES ANY AND ALL IMPLIED WARRANTIES OF MERCHANTABILITY, TITLE OR
  23. **    FITNESS FOR A PARTICULAR PURPOSE.
  24. **
  25. **    IN NO EVENT UNLESS REQUIRED BY APPLICABLE LAW WILL NOVELL OR ANY OTHER
  26. **    PARTY BE LIABLE FOR DAMAGES INCLUDING ANY GENERAL, SPECIAL, INCIDENTAL,
  27. **    CONSEQUENTIAL, INDIRECT OR PUNATIVE DAMAGES ARISING OUT OF THE USE OF
  28. **    OR INABLITITY TO USE THE WORK OR A MODIFIED WORK.
  29. **
  30. **    DSCONNBU.H - October 1994
  31. **
  32. **    Declaration of the DSConnBuffer class.
  33. **
  34. **    Author: John Buckle, Asia Pacific Support Centre, Novell Australia
  35. **    ==================================================================
  36. **    9 Jan 1995           First release              John Buckle
  37. */
  38.  
  39. # ifndef dsCONNBU_H
  40. # define dsCONNBU_H
  41.  
  42. # include "dsdefs.h"
  43. # include "dsbuffer.h"
  44. # include "dsconn.h"
  45.  
  46. /*
  47. ** Class DSConnBuffer
  48. **
  49. **    Combine the functionality of the DSBuffer and DSConn classes.
  50. */
  51.  
  52. class _DSCLASSDEC DSConnBuffer : public DSBuffer, public DSConn
  53. {
  54. protected:
  55.  
  56. public:
  57.             DSConnBuffer(
  58.                  NWPSTR context    = 0,
  59.                  DWORD  flags      = DSCPP_CONTEXT_FLAGS,
  60.                  WORD   inputSize  = DEFAULT_MESSAGE_LEN,
  61.                  WORD   outputSize = DEFAULT_MESSAGE_LEN,
  62.                  WORD   filterSize = DEFAULT_MESSAGE_LEN)
  63.             : DSBuffer(context,flags,inputSize,outputSize,filterSize)
  64.                 { Context = dContext ; }
  65.             DSConnBuffer(DSConnBuffer &) ;
  66.     virtual          ~ DSConnBuffer()             { ; }
  67.     void        operator=(DSConnBuffer &) ;
  68.             operator NWCONN_HANDLE()    { return ConnHandle ; }
  69.             operator NWDSContextHandle()    { return dContext ; }
  70.  
  71.     NWDSCCODE    status()     { return DSBuffer::Status ? DSBuffer::Status : DSConn::Status ; }
  72.     NWDSCCODE    reset ()     { return DSBuffer::Status = DSConn::Status = 0 ; }
  73. } ;
  74.  
  75. # endif dsCONNBU_H
  76.