dpp::dtemplate
dpp::json_interface< dtemplate >
dtemplate.h
struct friend struct json_interface< dtemplate > json_interface< dtemplate > dpp::dtemplate::json_interface< dtemplate > json_interface< dtemplate >
std::string std::string dpp::dtemplate::code code dpp::dtemplate::code

Template code.

time_t time_t dpp::dtemplate::created_at created_at dpp::dtemplate::created_at

Creation date/time.

snowflake snowflake dpp::dtemplate::creator_id creator_id dpp::dtemplate::creator_id

User ID of creator.

std::string std::string dpp::dtemplate::description description dpp::dtemplate::description

Template description.

bool bool dpp::dtemplate::is_dirty is_dirty dpp::dtemplate::is_dirty

True if needs synchronising.

std::string std::string dpp::dtemplate::name name dpp::dtemplate::name

Template name.

snowflake snowflake dpp::dtemplate::source_guild_id source_guild_id dpp::dtemplate::source_guild_id

Guild id the template is created from.

time_t time_t dpp::dtemplate::updated_at updated_at dpp::dtemplate::updated_at

Last update date/time.

uint32_t uint32_t dpp::dtemplate::usage_count usage_count dpp::dtemplate::usage_count

Usage counter.

dtemplate & dtemplate & dpp::dtemplate::fill_from_json_impl (nlohmann::json *j) fill_from_json_impl dpp::dtemplate::fill_from_json_impl nlohmann::json * j

Read class values from json object j

A json object to read from

A reference to self

json json dpp::dtemplate::to_json_impl (bool with_id=false) const to_json_impl dpp::dtemplate::to_json_impl bool with_id false

Build the JSON for this object.

with_id

Add ID to output

json JSON content

dpp::dtemplate::dtemplate
()
dtemplate
dpp::dtemplate::dtemplate

Construct a new dtemplate object.

virtual dpp::dtemplate::~dtemplate
()=default
~dtemplate
dpp::dtemplate::~dtemplate

Destroy the dtemplate object.

std::string std::string dpp::json_interface< dtemplate >::build_json (bool with_id=false) const build_json dpp::json_interface< dtemplate >::build_json bool with_id false

Convert object to json string.

with_id

Whether to include the ID or not

Some fields are conditionally filled, do not rely on all fields being present

std::string Json built from the structure

dtemplate & dtemplate & dpp::json_interface< dtemplate >::fill_from_json (nlohmann::json *j) fill_from_json dpp::json_interface< dtemplate >::fill_from_json nlohmann::json * j

Convert object from nlohmann::json.

j

nlohmann::json object

T& Reference to self for fluent calling

auto auto dpp::json_interface< dtemplate >::to_json (bool with_id=false) const to_json dpp::json_interface< dtemplate >::to_json bool with_id false

Convert object to nlohmann::json.

with_id

Whether to include the ID or not

Some fields are conditionally filled, do not rely on all fields being present

json Json built from the structure

Represents a guild template.

dpp::dtemplate
dpp::json_interface< T >
dpp::json_interface< dtemplate >
< dtemplate >
bool
dpp::dtemplate
code
description
name
usage_count
creator_id
source_guild_id
created_at
updated_at
is_dirty
dpp::json_interface< T >
dpp::json_interface< dtemplate >
< dtemplate >
dpp::snowflake
value
std::basic_string< Char >
std::string
time_t
uint32_t
uint64_t
- dpp::dtemplate
  build_json
- dpp::dtemplate
  code
- dpp::dtemplate
  created_at
- dpp::dtemplate
  creator_id
- dpp::dtemplate
  description
- dpp::dtemplate
  dtemplate
- dpp::dtemplate
  fill_from_json
- dpp::dtemplate
  fill_from_json_impl
- dpp::dtemplate
  is_dirty
- dpp::dtemplate
  json_interface< dtemplate >
- dpp::dtemplate
  name
- dpp::dtemplate
  source_guild_id
- dpp::dtemplate
  to_json
- dpp::dtemplate
  to_json_impl
- dpp::dtemplate
  updated_at
- dpp::dtemplate
  usage_count
- dpp::dtemplate
  ~dtemplate