Example #1
0
        private IProtoSerializer BuildSerializer()
        {
            // note the caller here is MetaType.BuildSerializer, which already has the sync-lock
            WireType wireType = WireType.String;

            if (dataFormat == DataFormat.Group)
            {
                wireType = WireType.StartGroup;                                // only one exception
            }
            IProtoSerializer ser = new SubItemSerializer(derivedType.Type, derivedType.GetKey(false, false), derivedType, false);

            return(new TagDecorator(fieldNumber, wireType, false, ser));
        }