Re: Does SerializeToXxx() guarantee a call to ByteSize()?

2008-09-22 Thread Kenton Varda
On Fri, Sep 19, 2008 at 7:39 PM, Leandro Lucarella <[EMAIL PROTECTED]> wrote: > > Kenton Varda, el 19 de septiembre a las 16:12 me escribiste: > > You probably shouldn't rely on this. Some of the serialization methods > will > > guarantee this, some won't. What you can do is call ByteSize() your

Re: Does SerializeToXxx() guarantee a call to ByteSize()?

2008-09-19 Thread Leandro Lucarella
Kenton Varda, el 19 de septiembre a las 16:12 me escribiste: > You probably shouldn't rely on this. Some of the serialization methods will > guarantee this, some won't. What you can do is call ByteSize() yourself, > and then use SerializeWithCachedSizes(), which requires that ByteSize() was > al

Re: Does SerializeToXxx() guarantee a call to ByteSize()?

2008-09-19 Thread Kenton Varda
You probably shouldn't rely on this. Some of the serialization methods will guarantee this, some won't. What you can do is call ByteSize() yourself, and then use SerializeWithCachedSizes(), which requires that ByteSize() was already called and won't call it again. You'll have to do a small amoun