Leaked source code of windows server 2003
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

55 lines
1.1 KiB

  1. /*
  2. * REVISIONS:
  3. * pcy29Nov92: Changed object.h to apcobj.h
  4. *
  5. * mwh05May94: #include file madness , part 2
  6. */
  7. #ifndef __NODE_H
  8. #define __NODE_H
  9. #include "_defs.h"
  10. #include "apc.h"
  11. #if !defined( __OBJECT_H)
  12. #include "apcobj.h"
  13. #endif
  14. _CLASSDEF(Node)
  15. class Node : public Obj {
  16. private:
  17. PNode theNext;
  18. PNode thePrev;
  19. PObj theData;
  20. friend class DoubleList;
  21. friend class DoubleListIterator;
  22. friend class List;
  23. friend class ListIterator;
  24. public:
  25. Node( PObj anObject, PNode aNode1 = (PNode)NULL,
  26. PNode aNode2 = (PNode)NULL ) : theNext((PNode)NULL),
  27. thePrev((PNode)NULL)
  28. { theData = anObject; theNext = aNode1; thePrev = aNode2; };
  29. VOID SetNext(PNode item);
  30. VOID SetPrev(PNode item);
  31. VOID SetData(PObj data);
  32. PObj GetData();
  33. PNode GetNext();
  34. PNode GetPrev();
  35. virtual INT IsA() const { return NODE; };
  36. virtual INT Equal( RObj anObject ) const { return theData->Equal(anObject); };
  37. };
  38. #endif