MCPcopy Create free account
hub / github.com/acl-dev/acl / save_to

Method save_to

lib_acl_cpp/src/smtp/mail_body.cpp:120–137  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

118}
119
120bool mail_body::save_to(string& out) const
121{
122 switch (mime_stype_) {
123 case MIME_STYPE_HTML:
124 return save_html(html_, hlen_, out);
125 case MIME_STYPE_PLAIN:
126 return save_plain(plain_, plen_, out);
127 case MIME_STYPE_ALTERNATIVE:
128 return save_alternative(html_, hlen_, plain_, plen_, out);
129 case MIME_STYPE_RELATED:
130 acl_assert(attachments_);
131 return save_relative(html_, hlen_, plain_, plen_,
132 *attachments_, out);
133 default:
134 logger_error("unknown mime_stype: %d", mime_stype_);
135 return false;
136 }
137}
138
139void mail_body::set_content_type(const char* content_type)
140{

Callers 1

save_relativeMethod · 0.45

Calls

no outgoing calls

Tested by

no test coverage detected