mFrame
載入中...
搜尋中...
無符合項目
Array.h
1
7#ifndef MFRAME_2F39A480_5C64_4E09_A926_7560E6BFF274
8#define MFRAME_2F39A480_5C64_4E09_A926_7560E6BFF274
9
10/* ***************************************************************************************
11 * Include
12 */
13
14//----------------------------------------------------------------------------------------
15
16//----------------------------------------------------------------------------------------
17#include "./../lang/Interface.h"
18
19/* ***************************************************************************************
20 * Namespace
21 */
22namespace ufm::util {
23 template <typename E>
24 struct Array;
25} // namespace ufm::util
26
27/* ***************************************************************************************
28 * Class/Interface/Struct/Enum
29 */
30
113template <typename E = void*>
115 /* *****************************************************************************************
116 * Method
117 */
125 virtual int length(void) const abstract;
126
135 virtual int indexOf(E& element) const abstract;
136
146 virtual E& get(int index) const abstract;
147
158 virtual bool set(E const& e, int index) abstract;
159
167 virtual int elementSize(void) const abstract;
168
169 /* *************************************************************************************
170 * Static Method
171 */
172};
173
174/* ***************************************************************************************
175 * End of file
176 */
177
178#endif /* MFRAME_2F39A480_5C64_4E09_A926_7560E6BFF274 */
Definition Iterable.h:28
通用陣列介面,提供基本的陣列操作功能。
Definition Array.h:114
virtual int length(void) const override
取得陣列長度
virtual bool set(E const &e, int index) override
設置指定索引的元素值
virtual E & get(int index) const override
取得指定索引的元素
virtual int elementSize(void) const override
取得元素大小
virtual int indexOf(E &element) const override
搜尋元素位置