larra/library/include/larra/bind.hpp
Ivan-lis b6c31e8e85
All checks were successful
PR Check / on-push-commit-check (push) Successful in 12m27s
Added auto serialization for Bind and Roster
2024-11-24 18:00:07 +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