setFlag method
Adds or removes the flag with the specified name to/from this message depending on value.
Note that this only affects this message instance and is not persisted or reported to the mail service automatically.
Implementation
void setFlag(String name, bool enable) {
if (enable == true) {
addFlag(name);
} else {
removeFlag(name);
}
}