writeBool method
Implementation
@override
void writeBool(bool? b) {
if (b == null) return;
if (booleanField_ != null) {
// we haven't written the field header yet
writeFieldBeginInternal(
booleanField_!, (b ? Types.BOOLEAN_TRUE : Types.BOOLEAN_FALSE));
booleanField_ = null;
} else {
// we're not part of a field, so just write the value.
writeByteDirect((b ? Types.BOOLEAN_TRUE : Types.BOOLEAN_FALSE));
}
}