Class to provide access to symbolic atoms.
More...
#include <base.hh>
|
auto | operator== (Atom const &a, Atom const &b) noexcept -> bool |
| Compare two atoms for equality.
|
|
auto | operator<=> (Atom const &a, Atom const &b) noexcept -> std::strong_ordering |
| Compare two atoms.
|
|
Class to provide access to symbolic atoms.
◆ Atom()
Construct an atom from its C representation.
For internal use.
- Parameters
-
base | the associated base |
index | the index of the atom |
◆ hash()
auto Clingo::Atom::hash |
( |
| ) |
const -> size_t |
|
inlinenoexcept |
Get the header of the atom.
The hash enables usage in hash tables. There is also an associtaed specialization of std::hash
for this class.
- Returns
- the atom's hash
◆ literal()
Get the program literal of the atom.
- Returns
- the program literal
◆ symbol()
auto Clingo::Atom::symbol |
( |
| ) |
const -> Symbol |
|
inline |
Get the atom's symbol.
- Returns
- the atom's symbol
◆ operator<=>
auto operator<=> |
( |
Atom const & |
a, |
|
|
Atom const & |
b |
|
) |
| -> std::strong_ordering |
|
friend |
Compare two atoms.
- Parameters
-
a | the first atom |
b | the second atom |
- Returns
- the result of the comparison
◆ operator==
auto operator== |
( |
Atom const & |
a, |
|
|
Atom const & |
b |
|
) |
| -> bool |
|
friend |
Compare two atoms for equality.
- Parameters
-
a | the first atom |
b | the second atom |
- Returns
- whether the two atoms are equal
The documentation for this class was generated from the following file: