Example #1
0
 public static int PB_MakeTag(int nFiledIndex, pb_type nType, PBValueType nValueType)
 {
     if (PBValueType.Value_Array == nValueType ||
         PBValueType.Value_Map == nValueType)
     {
         return(MakeTag(nFiledIndex, PB_WireType.WIRETYPE_LENGTH_DELIMITED));
     }
     else
     {
         PB_WireType nWiretType = PBTypeToWriteType(nType);
         return(MakeTag(nFiledIndex, nWiretType));
     }
 }
Example #2
0
 public static int MakeTag(int nFieldIndex, PB_WireType type)
 {
     return((nFieldIndex << 3) | (int)type);
 }