예제 #1
0
 protected void finish(TerrierUploadReadCommandJSON result)
 {
     if (fieldGeneratorBlockNameList.have_value)
     {
         result.initBlockNameList();
         int count = fieldGeneratorBlockNameList.value.Count;
         for (int num = 0; num < count; ++num)
         {
             result.appendBlockNameList(fieldGeneratorBlockNameList.value[num]);
         }
         fieldGeneratorBlockNameList.value.Clear();
         fieldGeneratorBlockNameList.have_value = false;
     }
     if (fieldGeneratorBlockDetails.have_value)
     {
         result.initBlockDetails();
         int count = fieldGeneratorBlockDetails.value.Count;
         for (int num = 0; num < count; ++num)
         {
             result.appendBlockDetails(fieldGeneratorBlockDetails.value[num]);
         }
         fieldGeneratorBlockDetails.value.Clear();
         fieldGeneratorBlockDetails.have_value = false;
     }
     base.finish(result);
 }
예제 #2
0
        protected override void finish()
        {
            if (!(getTerrierUploadCommandJSONKey().Equals("Read")))
            {
                throw new Exception("The key field has a value other than `Read'.");
            }
            TerrierUploadReadCommandJSON result = new TerrierUploadReadCommandJSON();

            Debug.Assert(result != null);
            finish(result);
            int extra_count = unknownFieldGenerator.field_names.Count;

            Debug.Assert(extra_count == unknownFieldGenerator.field_values.Count);
            for (int extra_num = 0; extra_num < extra_count; ++extra_num)
            {
                result.extraTerrierUploadReadCommandAppendPair(unknownFieldGenerator.field_names[extra_num], unknownFieldGenerator.field_values[extra_num]);
            }
            unknownFieldGenerator.field_names.Clear();
            unknownFieldGenerator.field_values.Clear();
            unknownFieldGenerator.index = new Dictionary <string, JSONValue>();
            handle_result(result);
        }
예제 #3
0
 protected override void handle_result(TerrierUploadReadCommandJSON result)
 {
     top.value.Add(result);
 }
예제 #4
0
        protected override void handle_result(TerrierUploadReadCommandJSON result)
        {
//@@@            Debug.Assert(!have_value);
            have_value = true;
            value      = result;
        }
예제 #5
0
 protected abstract void handle_result(TerrierUploadReadCommandJSON new_result);