Skip to content

Commit 5c12997

Browse files
author
nitrocaster
committed
Move function implementations to class definitions.
1 parent f568932 commit 5c12997

7 files changed

+19
-113
lines changed

src/xrAICore/Navigation/builder_allocator_constructor.h

Lines changed: 11 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -20,17 +20,19 @@ class BuilderAllocatorDataStorage :
2020
public:
2121
typedef typename _path_builder::template CDataStorage<_vertex> CDataStorageBase;
2222
typedef typename _vertex_allocator::template CDataStorage<
23-
typename _path_builder::template CDataStorage<
24-
_vertex
25-
>::CGraphVertex
26-
> CDataStorageAllocator;
23+
typename _path_builder::template CDataStorage<_vertex>::CGraphVertex> CDataStorageAllocator;
2724
typedef typename CDataStorageBase::CGraphVertex CGraphVertex;
2825
typedef typename CGraphVertex::_index_type _index_type;
2926

3027
public:
31-
IC BuilderAllocatorDataStorage(const u32 vertex_count);
32-
virtual ~BuilderAllocatorDataStorage();
33-
IC void init ();
28+
BuilderAllocatorDataStorage(const u32 vertex_count) :
29+
CDataStorageBase(vertex_count),
30+
CDataStorageAllocator()
31+
{}
32+
virtual ~BuilderAllocatorDataStorage() {}
33+
void init()
34+
{
35+
CDataStorageBase::init();
36+
CDataStorageAllocator::init();
37+
}
3438
};
35-
36-
#include "xrAICore/Navigation/builder_allocator_constructor_inline.h"

src/xrAICore/Navigation/builder_allocator_constructor_inline.h

Lines changed: 0 additions & 36 deletions
This file was deleted.

src/xrAICore/Navigation/data_storage_constructor.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,7 @@ template <
1818
typename _manager, // CVertexManagerFixed|CVertexManagerHashFixed
1919
typename _builder, // CEdgePath|CVertexPath
2020
typename _allocator, // CVertexAllocatorFixed
21-
template <typename _T> class _vertex = CEmptyClassTemplate
21+
template <typename _T> class _vertex = CEmptyClassTemplate // _Vertex
2222
>
2323
struct CDataStorageConstructor : // CDataStorageBucketList::CDataStorage<CManagerBuilderAllocatorConstructor<manager, path, allocator> >
2424
public _algorithm::template CDataStorage<

src/xrAICore/Navigation/manager_builder_allocator_constructor.h

Lines changed: 7 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -35,11 +35,12 @@ struct CManagerBuilderAllocatorConstructor {
3535
typedef typename CGraphVertex::_index_type _index_type;
3636

3737
public:
38-
IC CDataStorage (const u32 vertex_count);
39-
virtual ~CDataStorage ();
40-
IC void init ();
41-
IC CGraphVertex &create_vertex (const _index_type &vertex_id);
38+
CDataStorage(const u32 vertex_count) :
39+
inherited(vertex_count)
40+
{}
41+
virtual ~CDataStorage() {}
42+
void init() { inherited::init(); }
43+
CGraphVertex &create_vertex(const _index_type &vertex_id)
44+
{ return inherited::create_vertex(inherited_allocator::create_vertex(), vertex_id); }
4245
};
4346
};
44-
45-
#include "xrAICore/Navigation/manager_builder_allocator_constructor_inline.h"

src/xrAICore/Navigation/manager_builder_allocator_constructor_inline.h

Lines changed: 0 additions & 53 deletions
This file was deleted.

src/xrAICore/xrAICore.vcxproj

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -262,7 +262,6 @@
262262
<ClInclude Include="Navigation\a_star.h" />
263263
<ClInclude Include="Navigation\a_star_inline.h" />
264264
<ClInclude Include="Navigation\builder_allocator_constructor.h" />
265-
<ClInclude Include="Navigation\builder_allocator_constructor_inline.h" />
266265
<ClInclude Include="Navigation\data_storage_binary_heap.h" />
267266
<ClInclude Include="Navigation\data_storage_binary_heap_inline.h" />
268267
<ClInclude Include="Navigation\data_storage_bucket_list.h" />
@@ -291,7 +290,6 @@
291290
<ClInclude Include="Navigation\level_graph_space.h" />
292291
<ClInclude Include="Navigation\level_graph_vertex_inline.h" />
293292
<ClInclude Include="Navigation\manager_builder_allocator_constructor.h" />
294-
<ClInclude Include="Navigation\manager_builder_allocator_constructor_inline.h" />
295293
<ClInclude Include="Navigation\PathManagers\path_manager.h" />
296294
<ClInclude Include="Navigation\PathManagers\path_manager_game.h" />
297295
<ClInclude Include="Navigation\PathManagers\path_manager_game_inline.h" />

src/xrAICore/xrAICore.vcxproj.filters

Lines changed: 0 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -183,18 +183,12 @@
183183
<ClInclude Include="Navigation\builder_allocator_constructor.h">
184184
<Filter>AI\Navigation\Pathfinding\DataStorages\Constructors</Filter>
185185
</ClInclude>
186-
<ClInclude Include="Navigation\builder_allocator_constructor_inline.h">
187-
<Filter>AI\Navigation\Pathfinding\DataStorages\Constructors</Filter>
188-
</ClInclude>
189186
<ClInclude Include="Navigation\data_storage_constructor.h">
190187
<Filter>AI\Navigation\Pathfinding\DataStorages\Constructors</Filter>
191188
</ClInclude>
192189
<ClInclude Include="Navigation\manager_builder_allocator_constructor.h">
193190
<Filter>AI\Navigation\Pathfinding\DataStorages\Constructors</Filter>
194191
</ClInclude>
195-
<ClInclude Include="Navigation\manager_builder_allocator_constructor_inline.h">
196-
<Filter>AI\Navigation\Pathfinding\DataStorages\Constructors</Filter>
197-
</ClInclude>
198192
<ClInclude Include="Navigation\edge_path.h">
199193
<Filter>AI\Navigation\Pathfinding\DataStorages\PathBuilders</Filter>
200194
</ClInclude>

0 commit comments

Comments
 (0)