CTR Pia  4.11.3
Game Communication Engine
common_TreeMapNodeBase.h
1 /*---------------------------------------------------------------------------*
2  Project: Pia
3  File: common_TreeMapNodeBase.h
4 
5  Copyright Nintendo. All rights reserved.
6 
7  These coded instructions, statements, and computer programs contain
8  proprietary information of Nintendo of America Inc. and/or Nintendo
9  Company Ltd., and are protected by Federal copyright law. They may
10  not be disclosed to third parties or copied or duplicated in any form,
11  in whole or in part, without the prior written consent of Nintendo.
12  *---------------------------------------------------------------------------*/
13 
14 
15 #pragma once
16 
17 #include <pia/common/common_definitions.h>
18 
19 
20 namespace nn
21 {
22 namespace pia
23 {
24 namespace common
25 {
26 
27 class TreeMapBase;
28 
29 /*!
30 @cond PRIVATE
31 @brief Represents the class for treemap nodes.
32 */
33 class TreeMapNodeBase : public common::RootObject
34 {
35  friend class TreeMapBase;
36 
37 protected:
38  TreeMapNodeBase()
39  {
40  InitNodeBase();
41  }
42 
43 protected:
44  TreeMapNodeBase* PrevBase() const;
45 
46  TreeMapNodeBase* NextBase() const;
47 
48 protected:
49  void InitNodeBase();
50 
51  TreeMapNodeBase* GetLeftBase() const
52  {
53  return m_pLeft;
54  }
55  TreeMapNodeBase* GetRightBase() const
56  {
57  return m_pRight;
58  }
59 
60 private:
61  // Copying is prohibited.
62  TreeMapNodeBase(const TreeMapNodeBase& rhs);
63  TreeMapNodeBase& operator=(const TreeMapNodeBase& rhs);
64 
65 private:
66  TreeMapNodeBase* m_pUp;
67  TreeMapNodeBase* m_pLeft;
68  TreeMapNodeBase* m_pRight;
69  int m_Balance;
70 };
71 //! @endcond
72 }
73 }
74 } // end of namespace nn::pia::common
Definition: assert.h:115