2 * Copyright 2010, Haiku. All rights reserved.
3 * Distributed under the terms of the MIT License.
10 template<typename TYPE
>
11 GPArray
<TYPE
>::GPArray()
19 template<typename TYPE
>
20 GPArray
<TYPE
>::~GPArray()
23 for (int i
= 0; i
< fSize
; i
++)
31 template<typename TYPE
>
33 GPArray
<TYPE
>::SetSize(int size
)
35 ASSERT(fSize
== NULL
);
36 fArray
= new PointerType
[size
];
41 for (int i
= 0; i
< size
; i
++) {
47 template<typename TYPE
>
49 GPArray
<TYPE
>::Size() const
55 template<typename TYPE
>
57 GPArray
<TYPE
>::DecreaseSize()
59 ASSERT(fArray
!= NULL
);
60 ASSERT(fArray
[fSize
-1] == NULL
);
64 template<typename TYPE
>
66 GPArray
<TYPE
>::Array()
72 template<typename TYPE
>
74 GPArray
<TYPE
>::Array() const
79 template<typename TYPE
>
81 GPArray
<TYPE
>::IsEmpty() const