larra/library/include/larra/bind.hpp
2024-11-25 13:19:02 +00:00

24 lines
586 B
C++

#pragma once
#include <libxml++/libxml++.h>
#include <spdlog/spdlog.h>
#include <larra/iq.hpp>
#include <larra/jid.hpp>
#include <optional>
namespace larra::xmpp::iq {
struct Bind {
static constexpr auto kDefaultName = "bind";
static constexpr auto kDefaultNamespace = "urn:ietf:params:xml:ns:xmpp-bind";
std::optional<FullJid> jid;
friend auto operator<<(xmlpp::Element* element, const Bind& bind) -> void;
[[nodiscard]] static auto Parse(xmlpp::Element* element) -> Bind;
};
using SetBind = Set<Bind>;
using ResultBind = Result<Bind>;
} // namespace larra::xmpp::iq