Represents a sticker pack (the built in groups of stickers that all nitro users get to use) More...
#include "message.h"
Public Member Functions | |
std::string | build_json (bool with_id=false) const |
Convert object to json string. More... | |
sticker_pack & | fill_from_json (nlohmann::json *j) |
Convert object from nlohmann::json. More... | |
constexpr double | get_creation_time () const noexcept |
Get the creation time of this object according to Discord. More... | |
constexpr bool | operator!= (const managed &other) const noexcept |
Comparison operator for comparing two managed objects by id. More... | |
constexpr bool | operator== (const managed &other) const noexcept |
Comparison operator for comparing two managed objects by id. More... | |
auto | to_json (bool with_id=false) const |
Convert object to nlohmann::json. More... | |
Public Attributes | |
snowflake | banner_asset_id {} |
ID of the sticker pack's banner image. More... | |
snowflake | cover_sticker_id {0} |
Optional: ID of a sticker in the pack which is shown as the pack's icon. More... | |
std::string | description {} |
Description of the sticker pack. More... | |
snowflake | id = {} |
Unique ID of object set by Discord. More... | |
std::string | name {} |
Name of the sticker pack. More... | |
snowflake | sku_id {0} |
ID of the pack's SKU. More... | |
std::map< snowflake, sticker > | stickers {} |
The stickers in the pack. More... | |
Protected Member Functions | |
sticker_pack & | fill_from_json_impl (nlohmann::json *j) |
Read class values from json object. More... | |
virtual json | to_json_impl (bool with_id=true) const |
Build JSON from this object. More... | |
Friends | |
struct | json_interface< sticker_pack > |
Represents a sticker pack (the built in groups of stickers that all nitro users get to use)
|
inlineinherited |
Convert object to json string.
with_id | Whether to include the ID or not |
|
inlineinherited |
Convert object from nlohmann::json.
j | nlohmann::json object |
|
protected |
Read class values from json object.
j | A json object to read from |
|
inlineconstexprnoexceptinherited |
Get the creation time of this object according to Discord.
|
inlineconstexprnoexceptinherited |
Comparison operator for comparing two managed objects by id.
other | Other object to compare against |
|
inlineconstexprnoexceptinherited |
Comparison operator for comparing two managed objects by id.
other | Other object to compare against |
|
inlineinherited |
Convert object to nlohmann::json.
with_id | Whether to include the ID or not |
|
protectedvirtual |
Build JSON from this object.
with_id | True if the ID is to be set in the JSON structure |
|
friend |
snowflake dpp::sticker_pack::banner_asset_id {} |
ID of the sticker pack's banner image.
snowflake dpp::sticker_pack::cover_sticker_id {0} |
Optional: ID of a sticker in the pack which is shown as the pack's icon.
std::string dpp::sticker_pack::description {} |
Description of the sticker pack.
|
inherited |
Unique ID of object set by Discord.
This value contains a timestamp, worker ID, internal server ID, and an incrementing value. Only the timestamp is relevant to us as useful metadata.
Referenced by dpp::poll::add_answer(), dpp::cluster::create_webhook(), dpp::cluster::current_user_join_thread(), dpp::invite::fill_from_json_impl(), dpp::command_permission::fill_from_json_impl(), dpp::interaction::get_resolved_role(), dpp::interaction::get_resolved_user(), dpp::cluster::global_bulk_command_create(), dpp::cluster::global_bulk_command_delete(), dpp::cluster::global_command_delete(), dpp::cluster::global_command_edit(), dpp::cluster::guild_ban_delete(), dpp::cluster::guild_command_create(), dpp::cluster::guild_command_edit_permissions(), dpp::cluster::guild_get_integrations(), dpp::events::guild_member_update::handle(), dpp::events::guild_role_create::handle(), dpp::events::channel_create::handle(), dpp::events::voice_state_update::handle(), dpp::discord_voice_client::handle_frame(), main(), dpp::component::set_disabled(), and dpp::select_option::set_label().
std::string dpp::sticker_pack::name {} |
Name of the sticker pack.
snowflake dpp::sticker_pack::sku_id {0} |
ID of the pack's SKU.