.. _program_listing_file_src_rdf4cpp_Quad.hpp: Program Listing for File Quad.hpp ================================= |exhale_lsh| :ref:`Return to documentation for file ` (``src/rdf4cpp/Quad.hpp``) .. |exhale_lsh| unicode:: U+021B0 .. UPWARDS ARROW WITH TIP LEFTWARDS .. code-block:: cpp #ifndef RDF4CPP_QUAD_HPP #define RDF4CPP_QUAD_HPP #include #include namespace rdf4cpp { struct Quad : query::QuadPattern { Quad() noexcept = default; Quad(Node subject, Node predicate, Node object) noexcept; Quad(Node graph, Node subject, Node predicate, Node object) noexcept; [[nodiscard]] bool valid() const noexcept; static std::optional create_validated(Node graph, Node subject, Node predicate, Node object) noexcept; static std::optional create_validated(Node subject, Node predicate, Node object) noexcept; [[nodiscard]] Statement const &without_graph() const noexcept; [[nodiscard]] Quad to_node_storage(storage::DynNodeStoragePtr node_storage) const; [[nodiscard]] Quad try_get_in_node_storage(storage::DynNodeStoragePtr node_storage) const noexcept; bool serialize_ntriples(writer::BufWriterParts writer) const noexcept; bool serialize_nquads(writer::BufWriterParts writer) const noexcept; bool serialize_turtle(writer::SerializationState &state, writer::BufWriterParts writer) const noexcept; bool serialize_trig(writer::SerializationState &state, writer::BufWriterParts writer) const noexcept; }; } // namespace rdf4cpp template struct dice::hash::dice_hash_overload { static inline size_t dice_hash(rdf4cpp::Quad const &x) noexcept { return dice::hash::dice_hash_templates::dice_hash(std::tie(x.graph(), x.subject(), x.predicate(), x.object())); } }; #endif //RDF4CPP_QUAD_HPP