Go to the documentation of this file.
65 std::unique_ptr<FieldGeneratorBase> key_generator(
67 std::unique_ptr<FieldGeneratorBase> value_generator(
72 "private static readonly pbc::MapField<$key_type_name$, $value_type_name$>.Codec _map_$name$_codec\n"
73 " = new pbc::MapField<$key_type_name$, $value_type_name$>.Codec(");
74 key_generator->GenerateCodecCode(printer);
76 value_generator->GenerateCodecCode(printer);
80 "private readonly pbc::MapField<$key_type_name$, $value_type_name$> $name$_ = new pbc::MapField<$key_type_name$, $value_type_name$>();\n");
85 "$access_level$ pbc::MapField<$key_type_name$, $value_type_name$> $property_name$ {\n"
86 " get { return $name$_; }\n"
93 "$name$_.Add(other.$name$_);\n");
99 "$name$_.AddEntriesFrom(input, _map_$name$_codec);\n");
105 "$name$_.WriteTo(output, _map_$name$_codec);\n");
111 "size += $name$_.CalculateSize(_map_$name$_codec);\n");
117 "hash ^= $property_name$.GetHashCode();\n");
122 "if (!$property_name$.Equals(other.$property_name$)) return false;\n");
131 "$name$_ = other.$name$_.Clone();\n");
void Print(const std::map< std::string, std::string > &variables, const char *text)
virtual void WriteToString(io::Printer *printer)
virtual void GenerateMergingCode(io::Printer *printer)
const FieldDescriptor * descriptor_
virtual void GenerateParsingCode(io::Printer *printer)
virtual void WriteHash(io::Printer *printer)
std::map< string, string > variables_
void AddPublicMemberAttributes(io::Printer *printer)
virtual void WriteEquals(io::Printer *printer)
virtual void GenerateSerializedSizeCode(io::Printer *printer)
virtual void GenerateMembers(io::Printer *printer)
virtual void GenerateCloningCode(io::Printer *printer)
const FieldDescriptor * FindFieldByName(const std::string &name) const
const Options * options()
void WritePropertyDocComment(io::Printer *printer, const FieldDescriptor *field)
const Descriptor * message_type() const
virtual void GenerateSerializationCode(io::Printer *printer)
FieldGeneratorBase * CreateFieldGenerator(const FieldDescriptor *descriptor, int presenceIndex, const Options *options)
virtual void GenerateFreezingCode(io::Printer *printer)
MapFieldGenerator(const FieldDescriptor *descriptor, int presenceIndex, const Options *options)
libaditof
Author(s):
autogenerated on Wed May 21 2025 02:06:49