CTR-Pia
5.4.3
Game Communication Engine
メインページ
ネームスペース一覧
クラス構成
クラス索引
関連ページ
Result 検索
全て
クラス
ネームスペース
関数
変数
型定義
列挙型
列挙型の値
ページ
common_RootObject.h
1
/*--------------------------------------------------------------------------------*
2
Copyright (C)Nintendo All rights reserved.
3
4
These coded instructions, statements, and computer programs contain proprietary
5
information of Nintendo and/or its licensed developers and are protected by
6
national and international copyright laws. They may not be disclosed to third
7
parties or copied or duplicated in any form, in whole or in part, without the
8
prior written consent of Nintendo.
9
10
The content herein is highly confidential and should be handled accordingly.
11
*--------------------------------------------------------------------------------*/
12
13
14
#pragma once
15
16
#include <nn/pia/pia_Definitions.h>
17
18
#define NN_PIA_ENABLE_ROOTOBJECT_NEW 1
19
20
#if NN_PIA_ENABLE_ROOTOBJECT_NEW
21
#include <new>
22
#endif // end of NN_PIA_ENABLE_ROOTOBJECT_NEW
23
24
25
namespace
nn
26
{
27
namespace
pia
28
{
29
namespace
common
30
{
31
32
33
/*!
34
@brief Piaライブラリ内の共通基底クラスです。
35
36
*/
37
class
RootObject
38
{
39
public
:
40
/*!
41
@brief コンストラクタです。
42
*/
43
RootObject
(
void
)
44
{
45
}
46
47
48
#if NN_PIA_ENABLE_ROOTOBJECT_NEW
49
/*!
50
@cond PRIVATE
51
@brief プレーンなnewです。
52
*/
53
static
void
*
operator
new
(std::size_t size)
throw
();
54
//! @endcond
55
56
57
/*!
58
@cond PRIVATE
59
@brief 例外を投げないnewです。
60
*/
61
static
void
*
operator
new
(std::size_t size, std::nothrow_t)
throw
();
62
//! @endcond
63
64
65
/*!
66
@cond PRIVATE
67
@brief 配置newです。
68
*/
69
static
void
*
operator
new
(std::size_t,
void
* p)
throw
()
70
{
71
return
p;
72
}
73
//! @endcond
74
75
76
/*!
77
@cond PRIVATE
78
@brief プレーンなnewです
79
*/
80
static
void
*
operator
new
[](std::size_t size)
throw
();
81
//! @endcond
82
83
84
/*!
85
@cond PRIVATE
86
@brief 例外を投げないnewです(配列版)。
87
*/
88
static
void
*
operator
new
[](std::size_t size, std::nothrow_t)
throw
();
89
//! @endcond
90
91
92
/*!
93
@cond PRIVATE
94
@brief 配置newです(配列版)。
95
*/
96
static
void
*
operator
new
[](std::size_t,
void
* p)
throw
()
97
{
98
return
p;
99
}
100
//! @endcond
101
102
103
/*!
104
@cond PRIVATE
105
@brief delete演算子です。
106
*/
107
static
void
operator
delete
(
void
* p);
108
//! @endcond
109
110
111
/*!
112
@cond PRIVATE
113
@brief delete演算子です(配列版)。
114
*/
115
static
void
operator
delete
[](
void
* p);
116
//! @endcond
117
118
119
#if NN_PIA_WIN || NN_PIA_NINTENDOSDK
120
121
// Win では new に対応する delete が必要
122
123
/*!
124
@cond PRIVATE
125
@brief 例外を投げない new に対応する delete です。
126
*/
127
static
void
operator
delete
(
void
* p, std::nothrow_t)
throw
();
128
//! @endcond
129
130
/*!
131
@cond PRIVATE
132
@brief 配置 new に対応する delete です。
133
*/
134
static
void
operator
delete
(
void
* p,
void
*)
throw
();
135
//! @endcond
136
137
/*!
138
@cond PRIVATE
139
@brief 例外を投げない new に対応する delete です(配列版)。
140
*/
141
static
void
operator
delete
[](
void
* p, std::nothrow_t)
throw
();
142
//! @endcond
143
144
/*!
145
@cond PRIVATE
146
@brief 配置 new に対応する delete です(配列版)。
147
*/
148
static
void
operator
delete
[](
void
* p,
void
*)
throw
();
149
//! @endcond
150
151
#endif
152
153
#endif // end of NN_PIA_ENABLE_ROOTOBJECT_NEW
154
};
155
}
156
}
157
}
// end of namespace nn::pia::common
Include
nn
pia
common
common_RootObject.h
© 2016 Nintendo Co., Ltd. All rights reserved. 記載されている会社名、製品名等は、各社の登録商標または商標です。