public override void Encode(BinaryWriter writer) { if (Invalid) { Decoded.Encode(writer); } else { writer.Write(buffer, mapStart, byteCount); } }