faunus
Public Types | Public Member Functions | List of all members
Faunus::CellList::CellListDifference< TCellListMinuend, TCellListSubtrahend > Class Template Reference

Wrapper of two cell list to efficiently provide difference of members, i.e., members presented in the minuend and not in the subtrahend. More...

#include <celllistimpl.h>

Inheritance diagram for Faunus::CellList::CellListDifference< TCellListMinuend, TCellListSubtrahend >:
Inheritance graph
[legend]
Collaboration diagram for Faunus::CellList::CellListDifference< TCellListMinuend, TCellListSubtrahend >:
Collaboration graph
[legend]

Public Types

using AbstractCellList = typename CellListMinuend::AbstractCellList
 
using Grid = typename CellListMinuend::Grid
 
using Container = typename CellListMinuend::Container
 
- Public Types inherited from Faunus::CellList::AbstractImmutableCellList< ContainerTypeOf< ContainerOf< TCellListMinuend > >, GridTypeOf< GridOf< TCellListMinuend > > >
using AbstractCellList = AbstractImmutableCellList< ContainerTypeOf< ContainerOf< TCellListMinuend > >, GridTypeOf< GridOf< TCellListMinuend > > >
 
using ContainerType = ContainerTypeOf< ContainerOf< TCellListMinuend > >
 abstract container types
 
using GridType = GridTypeOf< GridOf< TCellListMinuend > >
 abstract grid type
 
using Members = typename Container::MembersOf< ContainerType >
 members type
 
using Member = typename Container::MemberOf< ContainerType >
 member type
 
using CellIndex = typename Grid::IndexOf< GridType >
 grid (cell) index type
 
using CellCoord = typename Grid::CoordOf< GridType >
 grid (cell) coordinates type
 

Public Member Functions

const MembersgetSortedMembers (const CellCoord &cell_coordinates) override
 < members type
 
const MembersgetMembers (const CellCoord &cell_coordinates) override
 Gets cell members at given cell coordinates.
 
const MembersgetNeighborSortedMembers (const CellCoord &cell_coordinates, const CellCoord &cell_offset) override
 
const MembersgetNeighborMembers (const CellCoord &cell_coordinates, const CellCoord &cell_offset) override
 Gets cell members at given cell coordinates.
 
CellIndex gridSize () const override
 Get cells count. Valid cell indices are in the range [0, gridSize).
 
auto & getGrid ()
 
std::vector< CellCoordgetCells () const override
 Gets indicies of non-empty cells. More...
 
 CellListDifference (std::shared_ptr< TCellListMinuend > minuend, std::shared_ptr< TCellListSubtrahend > subtrahend)
 

Detailed Description

template<typename TCellListMinuend, typename TCellListSubtrahend>
class Faunus::CellList::CellListDifference< TCellListMinuend, TCellListSubtrahend >

Wrapper of two cell list to efficiently provide difference of members, i.e., members presented in the minuend and not in the subtrahend.

Todo:
Allow cache invalidation when underlying cell lists change
Template Parameters
TCellListMinuend
TCellListSubtrahend

Member Function Documentation

◆ getCells()

template<typename TCellListMinuend , typename TCellListSubtrahend >
std::vector<CellCoord> Faunus::CellList::CellListDifference< TCellListMinuend, TCellListSubtrahend >::getCells ( ) const
inlineoverridevirtual

Gets indicies of non-empty cells.

See AbstractContainer interface.

Todo:
refactor as an iterator

Implements Faunus::CellList::AbstractImmutableCellList< ContainerTypeOf< ContainerOf< TCellListMinuend > >, GridTypeOf< GridOf< TCellListMinuend > > >.


The documentation for this class was generated from the following file: