Skip to content

Commit

Permalink
Move function implementations to class definitions.
Browse files Browse the repository at this point in the history
  • Loading branch information
nitrocaster committed Dec 10, 2015
1 parent f568932 commit 5c12997
Show file tree
Hide file tree
Showing 7 changed files with 19 additions and 113 deletions.
20 changes: 11 additions & 9 deletions src/xrAICore/Navigation/builder_allocator_constructor.h
Original file line number Diff line number Diff line change
Expand Up @@ -20,17 +20,19 @@ class BuilderAllocatorDataStorage :
public:
typedef typename _path_builder::template CDataStorage<_vertex> CDataStorageBase;
typedef typename _vertex_allocator::template CDataStorage<
typename _path_builder::template CDataStorage<
_vertex
>::CGraphVertex
> CDataStorageAllocator;
typename _path_builder::template CDataStorage<_vertex>::CGraphVertex> CDataStorageAllocator;
typedef typename CDataStorageBase::CGraphVertex CGraphVertex;
typedef typename CGraphVertex::_index_type _index_type;

public:
IC BuilderAllocatorDataStorage(const u32 vertex_count);
virtual ~BuilderAllocatorDataStorage();
IC void init ();
BuilderAllocatorDataStorage(const u32 vertex_count) :
CDataStorageBase(vertex_count),
CDataStorageAllocator()
{}
virtual ~BuilderAllocatorDataStorage() {}
void init()
{
CDataStorageBase::init();
CDataStorageAllocator::init();
}
};

#include "xrAICore/Navigation/builder_allocator_constructor_inline.h"
36 changes: 0 additions & 36 deletions src/xrAICore/Navigation/builder_allocator_constructor_inline.h

This file was deleted.

2 changes: 1 addition & 1 deletion src/xrAICore/Navigation/data_storage_constructor.h
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ template <
typename _manager, // CVertexManagerFixed|CVertexManagerHashFixed
typename _builder, // CEdgePath|CVertexPath
typename _allocator, // CVertexAllocatorFixed
template <typename _T> class _vertex = CEmptyClassTemplate
template <typename _T> class _vertex = CEmptyClassTemplate // _Vertex
>
struct CDataStorageConstructor : // CDataStorageBucketList::CDataStorage<CManagerBuilderAllocatorConstructor<manager, path, allocator> >
public _algorithm::template CDataStorage<
Expand Down
13 changes: 7 additions & 6 deletions src/xrAICore/Navigation/manager_builder_allocator_constructor.h
Original file line number Diff line number Diff line change
Expand Up @@ -35,11 +35,12 @@ struct CManagerBuilderAllocatorConstructor {
typedef typename CGraphVertex::_index_type _index_type;

public:
IC CDataStorage (const u32 vertex_count);
virtual ~CDataStorage ();
IC void init ();
IC CGraphVertex &create_vertex (const _index_type &vertex_id);
CDataStorage(const u32 vertex_count) :
inherited(vertex_count)
{}
virtual ~CDataStorage() {}
void init() { inherited::init(); }
CGraphVertex &create_vertex(const _index_type &vertex_id)
{ return inherited::create_vertex(inherited_allocator::create_vertex(), vertex_id); }
};
};

#include "xrAICore/Navigation/manager_builder_allocator_constructor_inline.h"

This file was deleted.

2 changes: 0 additions & 2 deletions src/xrAICore/xrAICore.vcxproj
Original file line number Diff line number Diff line change
Expand Up @@ -262,7 +262,6 @@
<ClInclude Include="Navigation\a_star.h" />
<ClInclude Include="Navigation\a_star_inline.h" />
<ClInclude Include="Navigation\builder_allocator_constructor.h" />
<ClInclude Include="Navigation\builder_allocator_constructor_inline.h" />
<ClInclude Include="Navigation\data_storage_binary_heap.h" />
<ClInclude Include="Navigation\data_storage_binary_heap_inline.h" />
<ClInclude Include="Navigation\data_storage_bucket_list.h" />
Expand Down Expand Up @@ -291,7 +290,6 @@
<ClInclude Include="Navigation\level_graph_space.h" />
<ClInclude Include="Navigation\level_graph_vertex_inline.h" />
<ClInclude Include="Navigation\manager_builder_allocator_constructor.h" />
<ClInclude Include="Navigation\manager_builder_allocator_constructor_inline.h" />
<ClInclude Include="Navigation\PathManagers\path_manager.h" />
<ClInclude Include="Navigation\PathManagers\path_manager_game.h" />
<ClInclude Include="Navigation\PathManagers\path_manager_game_inline.h" />
Expand Down
6 changes: 0 additions & 6 deletions src/xrAICore/xrAICore.vcxproj.filters
Original file line number Diff line number Diff line change
Expand Up @@ -183,18 +183,12 @@
<ClInclude Include="Navigation\builder_allocator_constructor.h">
<Filter>AI\Navigation\Pathfinding\DataStorages\Constructors</Filter>
</ClInclude>
<ClInclude Include="Navigation\builder_allocator_constructor_inline.h">
<Filter>AI\Navigation\Pathfinding\DataStorages\Constructors</Filter>
</ClInclude>
<ClInclude Include="Navigation\data_storage_constructor.h">
<Filter>AI\Navigation\Pathfinding\DataStorages\Constructors</Filter>
</ClInclude>
<ClInclude Include="Navigation\manager_builder_allocator_constructor.h">
<Filter>AI\Navigation\Pathfinding\DataStorages\Constructors</Filter>
</ClInclude>
<ClInclude Include="Navigation\manager_builder_allocator_constructor_inline.h">
<Filter>AI\Navigation\Pathfinding\DataStorages\Constructors</Filter>
</ClInclude>
<ClInclude Include="Navigation\edge_path.h">
<Filter>AI\Navigation\Pathfinding\DataStorages\PathBuilders</Filter>
</ClInclude>
Expand Down

0 comments on commit 5c12997

Please sign in to comment.