38 return static_cast<OwnershipState>(
static_cast<int64_t
>(a) &
static_cast<int64_t
>(b));
48 return static_cast<OwnershipState>(
static_cast<int64_t
>(a) |
static_cast<int64_t
>(b));
73 return "unknown state: 0b" + std::bitset<4>(
static_cast<int64_t
>(state)).to_string();
This is the main namespace of AutoPas.
Definition: AutoPasDecl.h:34
std::string format_as(const OwnershipState &state)
This function is needed to pass an ownership state to spdlog/fmt.
Definition: OwnershipState.h:64
constexpr int64_t toInt64(const OwnershipState a)
Returns the int64_t value of a given OwnershipState.
Definition: OwnershipState.h:57
constexpr OwnershipState operator|(const OwnershipState a, const OwnershipState b)
Bitwise OR operator for OwnershipState.
Definition: OwnershipState.h:47
OwnershipState
Enum that specifies the state of ownership.
Definition: OwnershipState.h:20
@ dummy
Dummy or deleted state, a particle with this state is not an actual particle!
@ halo
Halo state, a particle with this state is an actual particle, but not owned by the current AutoPas ob...
@ owned
Owned state, a particle with this state is an actual particle and owned by the current AutoPas object...
std::ostream & operator<<(std::ostream &os, const OwnershipState &ownershipState)
Insertion operator for OwnershipState.
Definition: OwnershipState.h:84
constexpr OwnershipState operator&(const OwnershipState a, const OwnershipState b)
Bitwise AND operator for OwnershipState.
Definition: OwnershipState.h:37