Re: [protobuf] Skip certain indices while encoding

2022-11-28 Thread LakshmiKanth Gupta
EmployeeDataMinimal solution doesn't work for me. Use case which I have is 
much more complex. But many thanks for your helping hand.



On Monday, November 28, 2022 at 10:26:11 AM UTC+1 marc.g...@gmail.com wrote:

> For 1 options: a) don't assign a value to salary (unless it is "required" 
> in proto2, which doesn't appear to be the case), or b) create a new 
> EmployeeDataMinimal message that *doesn't have a salary*, and serialize that
>
> (I can't comment on 2; not a C++ person)
>
> On Mon, 28 Nov 2022 at 08:14, LakshmiKanth Gupta  
> wrote:
>
>> Hello All,
>>
>> message EmployeeData
>> {
>> string name =1;
>> string address = 2;
>> integer salary =3;
>> }
>>
>> 1.
>> When I transmit the EmployeeData., I would like to skip "salary" from 
>> encoding.
>> Is that possible?
>> 2.
>> Is it possible to tag a void pointer with employeedata object in c++ 
>> code?  Some auxillary information
>>
>> All Inputs are much appreciated.
>>
>> Thanks in advance,
>>
>> with best regards,
>>Gupta 
>>
>> -- 
>> You received this message because you are subscribed to the Google Groups 
>> "Protocol Buffers" group.
>> To unsubscribe from this group and stop receiving emails from it, send an 
>> email to protobuf+u...@googlegroups.com.
>> To view this discussion on the web visit 
>> https://groups.google.com/d/msgid/protobuf/a380b0ec-287e-4d9b-8f5c-e9cb5718ef45n%40googlegroups.com
>>  
>> 
>> .
>>
>
>
> -- 
> Regards, 
>
> Marc
>

-- 
You received this message because you are subscribed to the Google Groups 
"Protocol Buffers" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to protobuf+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/protobuf/9d3b333a-b87a-4764-9cb9-120ff9115b83n%40googlegroups.com.


Re: [protobuf] Skip certain indices while encoding

2022-11-28 Thread Marc Gravell
For 1 options: a) don't assign a value to salary (unless it is "required"
in proto2, which doesn't appear to be the case), or b) create a new
EmployeeDataMinimal message that *doesn't have a salary*, and serialize that

(I can't comment on 2; not a C++ person)

On Mon, 28 Nov 2022 at 08:14, LakshmiKanth Gupta 
wrote:

> Hello All,
>
> message EmployeeData
> {
> string name =1;
> string address = 2;
> integer salary =3;
> }
>
> 1.
> When I transmit the EmployeeData., I would like to skip "salary" from
> encoding.
> Is that possible?
> 2.
> Is it possible to tag a void pointer with employeedata object in c++
> code?  Some auxillary information
>
> All Inputs are much appreciated.
>
> Thanks in advance,
>
> with best regards,
>Gupta
>
> --
> You received this message because you are subscribed to the Google Groups
> "Protocol Buffers" group.
> To unsubscribe from this group and stop receiving emails from it, send an
> email to protobuf+unsubscr...@googlegroups.com.
> To view this discussion on the web visit
> https://groups.google.com/d/msgid/protobuf/a380b0ec-287e-4d9b-8f5c-e9cb5718ef45n%40googlegroups.com
> 
> .
>


-- 
Regards,

Marc

-- 
You received this message because you are subscribed to the Google Groups 
"Protocol Buffers" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to protobuf+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/protobuf/CAF95VAxqvsWpVQyeS2UY7rhOpORjP1SQTn58SyrgSgfKrb%3DcLg%40mail.gmail.com.


[protobuf] Skip certain indices while encoding

2022-11-28 Thread LakshmiKanth Gupta
Hello All,

message EmployeeData
{
string name =1;
string address = 2;
integer salary =3;
}

1.
When I transmit the EmployeeData., I would like to skip "salary" from 
encoding.
Is that possible?
2.
Is it possible to tag a void pointer with employeedata object in c++ code?  
Some auxillary information

All Inputs are much appreciated.

Thanks in advance,

with best regards,
   Gupta 

-- 
You received this message because you are subscribed to the Google Groups 
"Protocol Buffers" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to protobuf+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/protobuf/a380b0ec-287e-4d9b-8f5c-e9cb5718ef45n%40googlegroups.com.