Function operator!=

Summary

#include <src/entt/entity/entity.hpp>

(1) constexpr bool operator!=([[maybe_unused]] const null_t other) const

(2) template <typename Entity>
    constexpr bool operator!=(const Entity entity) const

Function overload

Synopsis

#include <src/entt/entity/entity.hpp>

constexpr bool operator!=([[maybe_unused]] const null_t other) const

Description

Compares two null objects.

Parameters

other - A null object.

Returns
False in all cases.

Source

Lines 188-190 in src/entt/entity/entity.hpp.

[[nodiscard]] constexpr bool operator!=([[maybe_unused]] const null_t other) const ENTT_NOEXCEPT {
    return false;
}

Synopsis

#include <src/entt/entity/entity.hpp>

template <typename Entity>
constexpr bool operator!=(const Entity entity) const

Description

Compares a null object and an identifier of any type.

Template Parameters

Entity - Type of identifier.

Parameters

entity - Identifier with which to compare.

Returns
True if the two elements differ, false otherwise.

Source

Lines 210-213 in src/entt/entity/entity.hpp.

template<typename Entity>
[[nodiscard]] constexpr bool operator!=(const Entity entity) const ENTT_NOEXCEPT {
    return !(entity == *this);
}





Add Discussion

Log in to comment