github.com/hyperledger/burrow@v0.34.5-0.20220512172541-77f09336001d/js/proto/keys_pb.js (about)

     1  // source: keys.proto
     2  /**
     3   * @fileoverview
     4   * @enhanceable
     5   * @suppress {missingRequire} reports error on implicit type usages.
     6   * @suppress {messageConventions} JS Compiler reports an error if a variable or
     7   *     field starts with 'MSG_' and isn't a translatable message.
     8   * @public
     9   */
    10  // GENERATED CODE -- DO NOT EDIT!
    11  /* eslint-disable */
    12  // @ts-nocheck
    13  
    14  var jspb = require('google-protobuf');
    15  var goog = jspb;
    16  var global = Function('return this')();
    17  
    18  var gogoproto_gogo_pb = require('./gogoproto/gogo_pb.js');
    19  goog.object.extend(proto, gogoproto_gogo_pb);
    20  var crypto_pb = require('./crypto_pb.js');
    21  goog.object.extend(proto, crypto_pb);
    22  goog.exportSymbol('proto.keys.AddNameRequest', null, global);
    23  goog.exportSymbol('proto.keys.AddNameResponse', null, global);
    24  goog.exportSymbol('proto.keys.ExportRequest', null, global);
    25  goog.exportSymbol('proto.keys.ExportResponse', null, global);
    26  goog.exportSymbol('proto.keys.GenRequest', null, global);
    27  goog.exportSymbol('proto.keys.GenResponse', null, global);
    28  goog.exportSymbol('proto.keys.HashRequest', null, global);
    29  goog.exportSymbol('proto.keys.HashResponse', null, global);
    30  goog.exportSymbol('proto.keys.ImportJSONRequest', null, global);
    31  goog.exportSymbol('proto.keys.ImportRequest', null, global);
    32  goog.exportSymbol('proto.keys.ImportResponse', null, global);
    33  goog.exportSymbol('proto.keys.KeyID', null, global);
    34  goog.exportSymbol('proto.keys.ListRequest', null, global);
    35  goog.exportSymbol('proto.keys.ListResponse', null, global);
    36  goog.exportSymbol('proto.keys.PubRequest', null, global);
    37  goog.exportSymbol('proto.keys.PubResponse', null, global);
    38  goog.exportSymbol('proto.keys.RemoveNameRequest', null, global);
    39  goog.exportSymbol('proto.keys.RemoveNameResponse', null, global);
    40  goog.exportSymbol('proto.keys.SignRequest', null, global);
    41  goog.exportSymbol('proto.keys.SignResponse', null, global);
    42  goog.exportSymbol('proto.keys.VerifyRequest', null, global);
    43  goog.exportSymbol('proto.keys.VerifyResponse', null, global);
    44  /**
    45   * Generated by JsPbCodeGenerator.
    46   * @param {Array=} opt_data Optional initial data array, typically from a
    47   * server response, or constructed directly in Javascript. The array is used
    48   * in place and becomes part of the constructed object. It is not cloned.
    49   * If no data is provided, the constructed object will be empty, but still
    50   * valid.
    51   * @extends {jspb.Message}
    52   * @constructor
    53   */
    54  proto.keys.ListRequest = function(opt_data) {
    55    jspb.Message.initialize(this, opt_data, 0, -1, null, null);
    56  };
    57  goog.inherits(proto.keys.ListRequest, jspb.Message);
    58  if (goog.DEBUG && !COMPILED) {
    59    /**
    60     * @public
    61     * @override
    62     */
    63    proto.keys.ListRequest.displayName = 'proto.keys.ListRequest';
    64  }
    65  /**
    66   * Generated by JsPbCodeGenerator.
    67   * @param {Array=} opt_data Optional initial data array, typically from a
    68   * server response, or constructed directly in Javascript. The array is used
    69   * in place and becomes part of the constructed object. It is not cloned.
    70   * If no data is provided, the constructed object will be empty, but still
    71   * valid.
    72   * @extends {jspb.Message}
    73   * @constructor
    74   */
    75  proto.keys.VerifyResponse = function(opt_data) {
    76    jspb.Message.initialize(this, opt_data, 0, -1, null, null);
    77  };
    78  goog.inherits(proto.keys.VerifyResponse, jspb.Message);
    79  if (goog.DEBUG && !COMPILED) {
    80    /**
    81     * @public
    82     * @override
    83     */
    84    proto.keys.VerifyResponse.displayName = 'proto.keys.VerifyResponse';
    85  }
    86  /**
    87   * Generated by JsPbCodeGenerator.
    88   * @param {Array=} opt_data Optional initial data array, typically from a
    89   * server response, or constructed directly in Javascript. The array is used
    90   * in place and becomes part of the constructed object. It is not cloned.
    91   * If no data is provided, the constructed object will be empty, but still
    92   * valid.
    93   * @extends {jspb.Message}
    94   * @constructor
    95   */
    96  proto.keys.RemoveNameResponse = function(opt_data) {
    97    jspb.Message.initialize(this, opt_data, 0, -1, null, null);
    98  };
    99  goog.inherits(proto.keys.RemoveNameResponse, jspb.Message);
   100  if (goog.DEBUG && !COMPILED) {
   101    /**
   102     * @public
   103     * @override
   104     */
   105    proto.keys.RemoveNameResponse.displayName = 'proto.keys.RemoveNameResponse';
   106  }
   107  /**
   108   * Generated by JsPbCodeGenerator.
   109   * @param {Array=} opt_data Optional initial data array, typically from a
   110   * server response, or constructed directly in Javascript. The array is used
   111   * in place and becomes part of the constructed object. It is not cloned.
   112   * If no data is provided, the constructed object will be empty, but still
   113   * valid.
   114   * @extends {jspb.Message}
   115   * @constructor
   116   */
   117  proto.keys.AddNameResponse = function(opt_data) {
   118    jspb.Message.initialize(this, opt_data, 0, -1, null, null);
   119  };
   120  goog.inherits(proto.keys.AddNameResponse, jspb.Message);
   121  if (goog.DEBUG && !COMPILED) {
   122    /**
   123     * @public
   124     * @override
   125     */
   126    proto.keys.AddNameResponse.displayName = 'proto.keys.AddNameResponse';
   127  }
   128  /**
   129   * Generated by JsPbCodeGenerator.
   130   * @param {Array=} opt_data Optional initial data array, typically from a
   131   * server response, or constructed directly in Javascript. The array is used
   132   * in place and becomes part of the constructed object. It is not cloned.
   133   * If no data is provided, the constructed object will be empty, but still
   134   * valid.
   135   * @extends {jspb.Message}
   136   * @constructor
   137   */
   138  proto.keys.RemoveNameRequest = function(opt_data) {
   139    jspb.Message.initialize(this, opt_data, 0, -1, null, null);
   140  };
   141  goog.inherits(proto.keys.RemoveNameRequest, jspb.Message);
   142  if (goog.DEBUG && !COMPILED) {
   143    /**
   144     * @public
   145     * @override
   146     */
   147    proto.keys.RemoveNameRequest.displayName = 'proto.keys.RemoveNameRequest';
   148  }
   149  /**
   150   * Generated by JsPbCodeGenerator.
   151   * @param {Array=} opt_data Optional initial data array, typically from a
   152   * server response, or constructed directly in Javascript. The array is used
   153   * in place and becomes part of the constructed object. It is not cloned.
   154   * If no data is provided, the constructed object will be empty, but still
   155   * valid.
   156   * @extends {jspb.Message}
   157   * @constructor
   158   */
   159  proto.keys.GenRequest = function(opt_data) {
   160    jspb.Message.initialize(this, opt_data, 0, -1, null, null);
   161  };
   162  goog.inherits(proto.keys.GenRequest, jspb.Message);
   163  if (goog.DEBUG && !COMPILED) {
   164    /**
   165     * @public
   166     * @override
   167     */
   168    proto.keys.GenRequest.displayName = 'proto.keys.GenRequest';
   169  }
   170  /**
   171   * Generated by JsPbCodeGenerator.
   172   * @param {Array=} opt_data Optional initial data array, typically from a
   173   * server response, or constructed directly in Javascript. The array is used
   174   * in place and becomes part of the constructed object. It is not cloned.
   175   * If no data is provided, the constructed object will be empty, but still
   176   * valid.
   177   * @extends {jspb.Message}
   178   * @constructor
   179   */
   180  proto.keys.GenResponse = function(opt_data) {
   181    jspb.Message.initialize(this, opt_data, 0, -1, null, null);
   182  };
   183  goog.inherits(proto.keys.GenResponse, jspb.Message);
   184  if (goog.DEBUG && !COMPILED) {
   185    /**
   186     * @public
   187     * @override
   188     */
   189    proto.keys.GenResponse.displayName = 'proto.keys.GenResponse';
   190  }
   191  /**
   192   * Generated by JsPbCodeGenerator.
   193   * @param {Array=} opt_data Optional initial data array, typically from a
   194   * server response, or constructed directly in Javascript. The array is used
   195   * in place and becomes part of the constructed object. It is not cloned.
   196   * If no data is provided, the constructed object will be empty, but still
   197   * valid.
   198   * @extends {jspb.Message}
   199   * @constructor
   200   */
   201  proto.keys.PubRequest = function(opt_data) {
   202    jspb.Message.initialize(this, opt_data, 0, -1, null, null);
   203  };
   204  goog.inherits(proto.keys.PubRequest, jspb.Message);
   205  if (goog.DEBUG && !COMPILED) {
   206    /**
   207     * @public
   208     * @override
   209     */
   210    proto.keys.PubRequest.displayName = 'proto.keys.PubRequest';
   211  }
   212  /**
   213   * Generated by JsPbCodeGenerator.
   214   * @param {Array=} opt_data Optional initial data array, typically from a
   215   * server response, or constructed directly in Javascript. The array is used
   216   * in place and becomes part of the constructed object. It is not cloned.
   217   * If no data is provided, the constructed object will be empty, but still
   218   * valid.
   219   * @extends {jspb.Message}
   220   * @constructor
   221   */
   222  proto.keys.PubResponse = function(opt_data) {
   223    jspb.Message.initialize(this, opt_data, 0, -1, null, null);
   224  };
   225  goog.inherits(proto.keys.PubResponse, jspb.Message);
   226  if (goog.DEBUG && !COMPILED) {
   227    /**
   228     * @public
   229     * @override
   230     */
   231    proto.keys.PubResponse.displayName = 'proto.keys.PubResponse';
   232  }
   233  /**
   234   * Generated by JsPbCodeGenerator.
   235   * @param {Array=} opt_data Optional initial data array, typically from a
   236   * server response, or constructed directly in Javascript. The array is used
   237   * in place and becomes part of the constructed object. It is not cloned.
   238   * If no data is provided, the constructed object will be empty, but still
   239   * valid.
   240   * @extends {jspb.Message}
   241   * @constructor
   242   */
   243  proto.keys.ImportJSONRequest = function(opt_data) {
   244    jspb.Message.initialize(this, opt_data, 0, -1, null, null);
   245  };
   246  goog.inherits(proto.keys.ImportJSONRequest, jspb.Message);
   247  if (goog.DEBUG && !COMPILED) {
   248    /**
   249     * @public
   250     * @override
   251     */
   252    proto.keys.ImportJSONRequest.displayName = 'proto.keys.ImportJSONRequest';
   253  }
   254  /**
   255   * Generated by JsPbCodeGenerator.
   256   * @param {Array=} opt_data Optional initial data array, typically from a
   257   * server response, or constructed directly in Javascript. The array is used
   258   * in place and becomes part of the constructed object. It is not cloned.
   259   * If no data is provided, the constructed object will be empty, but still
   260   * valid.
   261   * @extends {jspb.Message}
   262   * @constructor
   263   */
   264  proto.keys.ImportResponse = function(opt_data) {
   265    jspb.Message.initialize(this, opt_data, 0, -1, null, null);
   266  };
   267  goog.inherits(proto.keys.ImportResponse, jspb.Message);
   268  if (goog.DEBUG && !COMPILED) {
   269    /**
   270     * @public
   271     * @override
   272     */
   273    proto.keys.ImportResponse.displayName = 'proto.keys.ImportResponse';
   274  }
   275  /**
   276   * Generated by JsPbCodeGenerator.
   277   * @param {Array=} opt_data Optional initial data array, typically from a
   278   * server response, or constructed directly in Javascript. The array is used
   279   * in place and becomes part of the constructed object. It is not cloned.
   280   * If no data is provided, the constructed object will be empty, but still
   281   * valid.
   282   * @extends {jspb.Message}
   283   * @constructor
   284   */
   285  proto.keys.ImportRequest = function(opt_data) {
   286    jspb.Message.initialize(this, opt_data, 0, -1, null, null);
   287  };
   288  goog.inherits(proto.keys.ImportRequest, jspb.Message);
   289  if (goog.DEBUG && !COMPILED) {
   290    /**
   291     * @public
   292     * @override
   293     */
   294    proto.keys.ImportRequest.displayName = 'proto.keys.ImportRequest';
   295  }
   296  /**
   297   * Generated by JsPbCodeGenerator.
   298   * @param {Array=} opt_data Optional initial data array, typically from a
   299   * server response, or constructed directly in Javascript. The array is used
   300   * in place and becomes part of the constructed object. It is not cloned.
   301   * If no data is provided, the constructed object will be empty, but still
   302   * valid.
   303   * @extends {jspb.Message}
   304   * @constructor
   305   */
   306  proto.keys.ExportRequest = function(opt_data) {
   307    jspb.Message.initialize(this, opt_data, 0, -1, null, null);
   308  };
   309  goog.inherits(proto.keys.ExportRequest, jspb.Message);
   310  if (goog.DEBUG && !COMPILED) {
   311    /**
   312     * @public
   313     * @override
   314     */
   315    proto.keys.ExportRequest.displayName = 'proto.keys.ExportRequest';
   316  }
   317  /**
   318   * Generated by JsPbCodeGenerator.
   319   * @param {Array=} opt_data Optional initial data array, typically from a
   320   * server response, or constructed directly in Javascript. The array is used
   321   * in place and becomes part of the constructed object. It is not cloned.
   322   * If no data is provided, the constructed object will be empty, but still
   323   * valid.
   324   * @extends {jspb.Message}
   325   * @constructor
   326   */
   327  proto.keys.ExportResponse = function(opt_data) {
   328    jspb.Message.initialize(this, opt_data, 0, -1, null, null);
   329  };
   330  goog.inherits(proto.keys.ExportResponse, jspb.Message);
   331  if (goog.DEBUG && !COMPILED) {
   332    /**
   333     * @public
   334     * @override
   335     */
   336    proto.keys.ExportResponse.displayName = 'proto.keys.ExportResponse';
   337  }
   338  /**
   339   * Generated by JsPbCodeGenerator.
   340   * @param {Array=} opt_data Optional initial data array, typically from a
   341   * server response, or constructed directly in Javascript. The array is used
   342   * in place and becomes part of the constructed object. It is not cloned.
   343   * If no data is provided, the constructed object will be empty, but still
   344   * valid.
   345   * @extends {jspb.Message}
   346   * @constructor
   347   */
   348  proto.keys.SignRequest = function(opt_data) {
   349    jspb.Message.initialize(this, opt_data, 0, -1, null, null);
   350  };
   351  goog.inherits(proto.keys.SignRequest, jspb.Message);
   352  if (goog.DEBUG && !COMPILED) {
   353    /**
   354     * @public
   355     * @override
   356     */
   357    proto.keys.SignRequest.displayName = 'proto.keys.SignRequest';
   358  }
   359  /**
   360   * Generated by JsPbCodeGenerator.
   361   * @param {Array=} opt_data Optional initial data array, typically from a
   362   * server response, or constructed directly in Javascript. The array is used
   363   * in place and becomes part of the constructed object. It is not cloned.
   364   * If no data is provided, the constructed object will be empty, but still
   365   * valid.
   366   * @extends {jspb.Message}
   367   * @constructor
   368   */
   369  proto.keys.SignResponse = function(opt_data) {
   370    jspb.Message.initialize(this, opt_data, 0, -1, null, null);
   371  };
   372  goog.inherits(proto.keys.SignResponse, jspb.Message);
   373  if (goog.DEBUG && !COMPILED) {
   374    /**
   375     * @public
   376     * @override
   377     */
   378    proto.keys.SignResponse.displayName = 'proto.keys.SignResponse';
   379  }
   380  /**
   381   * Generated by JsPbCodeGenerator.
   382   * @param {Array=} opt_data Optional initial data array, typically from a
   383   * server response, or constructed directly in Javascript. The array is used
   384   * in place and becomes part of the constructed object. It is not cloned.
   385   * If no data is provided, the constructed object will be empty, but still
   386   * valid.
   387   * @extends {jspb.Message}
   388   * @constructor
   389   */
   390  proto.keys.VerifyRequest = function(opt_data) {
   391    jspb.Message.initialize(this, opt_data, 0, -1, null, null);
   392  };
   393  goog.inherits(proto.keys.VerifyRequest, jspb.Message);
   394  if (goog.DEBUG && !COMPILED) {
   395    /**
   396     * @public
   397     * @override
   398     */
   399    proto.keys.VerifyRequest.displayName = 'proto.keys.VerifyRequest';
   400  }
   401  /**
   402   * Generated by JsPbCodeGenerator.
   403   * @param {Array=} opt_data Optional initial data array, typically from a
   404   * server response, or constructed directly in Javascript. The array is used
   405   * in place and becomes part of the constructed object. It is not cloned.
   406   * If no data is provided, the constructed object will be empty, but still
   407   * valid.
   408   * @extends {jspb.Message}
   409   * @constructor
   410   */
   411  proto.keys.HashRequest = function(opt_data) {
   412    jspb.Message.initialize(this, opt_data, 0, -1, null, null);
   413  };
   414  goog.inherits(proto.keys.HashRequest, jspb.Message);
   415  if (goog.DEBUG && !COMPILED) {
   416    /**
   417     * @public
   418     * @override
   419     */
   420    proto.keys.HashRequest.displayName = 'proto.keys.HashRequest';
   421  }
   422  /**
   423   * Generated by JsPbCodeGenerator.
   424   * @param {Array=} opt_data Optional initial data array, typically from a
   425   * server response, or constructed directly in Javascript. The array is used
   426   * in place and becomes part of the constructed object. It is not cloned.
   427   * If no data is provided, the constructed object will be empty, but still
   428   * valid.
   429   * @extends {jspb.Message}
   430   * @constructor
   431   */
   432  proto.keys.HashResponse = function(opt_data) {
   433    jspb.Message.initialize(this, opt_data, 0, -1, null, null);
   434  };
   435  goog.inherits(proto.keys.HashResponse, jspb.Message);
   436  if (goog.DEBUG && !COMPILED) {
   437    /**
   438     * @public
   439     * @override
   440     */
   441    proto.keys.HashResponse.displayName = 'proto.keys.HashResponse';
   442  }
   443  /**
   444   * Generated by JsPbCodeGenerator.
   445   * @param {Array=} opt_data Optional initial data array, typically from a
   446   * server response, or constructed directly in Javascript. The array is used
   447   * in place and becomes part of the constructed object. It is not cloned.
   448   * If no data is provided, the constructed object will be empty, but still
   449   * valid.
   450   * @extends {jspb.Message}
   451   * @constructor
   452   */
   453  proto.keys.KeyID = function(opt_data) {
   454    jspb.Message.initialize(this, opt_data, 0, -1, proto.keys.KeyID.repeatedFields_, null);
   455  };
   456  goog.inherits(proto.keys.KeyID, jspb.Message);
   457  if (goog.DEBUG && !COMPILED) {
   458    /**
   459     * @public
   460     * @override
   461     */
   462    proto.keys.KeyID.displayName = 'proto.keys.KeyID';
   463  }
   464  /**
   465   * Generated by JsPbCodeGenerator.
   466   * @param {Array=} opt_data Optional initial data array, typically from a
   467   * server response, or constructed directly in Javascript. The array is used
   468   * in place and becomes part of the constructed object. It is not cloned.
   469   * If no data is provided, the constructed object will be empty, but still
   470   * valid.
   471   * @extends {jspb.Message}
   472   * @constructor
   473   */
   474  proto.keys.ListResponse = function(opt_data) {
   475    jspb.Message.initialize(this, opt_data, 0, -1, proto.keys.ListResponse.repeatedFields_, null);
   476  };
   477  goog.inherits(proto.keys.ListResponse, jspb.Message);
   478  if (goog.DEBUG && !COMPILED) {
   479    /**
   480     * @public
   481     * @override
   482     */
   483    proto.keys.ListResponse.displayName = 'proto.keys.ListResponse';
   484  }
   485  /**
   486   * Generated by JsPbCodeGenerator.
   487   * @param {Array=} opt_data Optional initial data array, typically from a
   488   * server response, or constructed directly in Javascript. The array is used
   489   * in place and becomes part of the constructed object. It is not cloned.
   490   * If no data is provided, the constructed object will be empty, but still
   491   * valid.
   492   * @extends {jspb.Message}
   493   * @constructor
   494   */
   495  proto.keys.AddNameRequest = function(opt_data) {
   496    jspb.Message.initialize(this, opt_data, 0, -1, null, null);
   497  };
   498  goog.inherits(proto.keys.AddNameRequest, jspb.Message);
   499  if (goog.DEBUG && !COMPILED) {
   500    /**
   501     * @public
   502     * @override
   503     */
   504    proto.keys.AddNameRequest.displayName = 'proto.keys.AddNameRequest';
   505  }
   506  
   507  
   508  
   509  if (jspb.Message.GENERATE_TO_OBJECT) {
   510  /**
   511   * Creates an object representation of this proto.
   512   * Field names that are reserved in JavaScript and will be renamed to pb_name.
   513   * Optional fields that are not set will be set to undefined.
   514   * To access a reserved field use, foo.pb_<name>, eg, foo.pb_default.
   515   * For the list of reserved names please see:
   516   *     net/proto2/compiler/js/internal/generator.cc#kKeyword.
   517   * @param {boolean=} opt_includeInstance Deprecated. whether to include the
   518   *     JSPB instance for transitional soy proto support:
   519   *     http://goto/soy-param-migration
   520   * @return {!Object}
   521   */
   522  proto.keys.ListRequest.prototype.toObject = function(opt_includeInstance) {
   523    return proto.keys.ListRequest.toObject(opt_includeInstance, this);
   524  };
   525  
   526  
   527  /**
   528   * Static version of the {@see toObject} method.
   529   * @param {boolean|undefined} includeInstance Deprecated. Whether to include
   530   *     the JSPB instance for transitional soy proto support:
   531   *     http://goto/soy-param-migration
   532   * @param {!proto.keys.ListRequest} msg The msg instance to transform.
   533   * @return {!Object}
   534   * @suppress {unusedLocalVariables} f is only used for nested messages
   535   */
   536  proto.keys.ListRequest.toObject = function(includeInstance, msg) {
   537    var f, obj = {
   538      keyname: jspb.Message.getFieldWithDefault(msg, 1, "")
   539    };
   540  
   541    if (includeInstance) {
   542      obj.$jspbMessageInstance = msg;
   543    }
   544    return obj;
   545  };
   546  }
   547  
   548  
   549  /**
   550   * Deserializes binary data (in protobuf wire format).
   551   * @param {jspb.ByteSource} bytes The bytes to deserialize.
   552   * @return {!proto.keys.ListRequest}
   553   */
   554  proto.keys.ListRequest.deserializeBinary = function(bytes) {
   555    var reader = new jspb.BinaryReader(bytes);
   556    var msg = new proto.keys.ListRequest;
   557    return proto.keys.ListRequest.deserializeBinaryFromReader(msg, reader);
   558  };
   559  
   560  
   561  /**
   562   * Deserializes binary data (in protobuf wire format) from the
   563   * given reader into the given message object.
   564   * @param {!proto.keys.ListRequest} msg The message object to deserialize into.
   565   * @param {!jspb.BinaryReader} reader The BinaryReader to use.
   566   * @return {!proto.keys.ListRequest}
   567   */
   568  proto.keys.ListRequest.deserializeBinaryFromReader = function(msg, reader) {
   569    while (reader.nextField()) {
   570      if (reader.isEndGroup()) {
   571        break;
   572      }
   573      var field = reader.getFieldNumber();
   574      switch (field) {
   575      case 1:
   576        var value = /** @type {string} */ (reader.readString());
   577        msg.setKeyname(value);
   578        break;
   579      default:
   580        reader.skipField();
   581        break;
   582      }
   583    }
   584    return msg;
   585  };
   586  
   587  
   588  /**
   589   * Serializes the message to binary data (in protobuf wire format).
   590   * @return {!Uint8Array}
   591   */
   592  proto.keys.ListRequest.prototype.serializeBinary = function() {
   593    var writer = new jspb.BinaryWriter();
   594    proto.keys.ListRequest.serializeBinaryToWriter(this, writer);
   595    return writer.getResultBuffer();
   596  };
   597  
   598  
   599  /**
   600   * Serializes the given message to binary data (in protobuf wire
   601   * format), writing to the given BinaryWriter.
   602   * @param {!proto.keys.ListRequest} message
   603   * @param {!jspb.BinaryWriter} writer
   604   * @suppress {unusedLocalVariables} f is only used for nested messages
   605   */
   606  proto.keys.ListRequest.serializeBinaryToWriter = function(message, writer) {
   607    var f = undefined;
   608    f = message.getKeyname();
   609    if (f.length > 0) {
   610      writer.writeString(
   611        1,
   612        f
   613      );
   614    }
   615  };
   616  
   617  
   618  /**
   619   * optional string KeyName = 1;
   620   * @return {string}
   621   */
   622  proto.keys.ListRequest.prototype.getKeyname = function() {
   623    return /** @type {string} */ (jspb.Message.getFieldWithDefault(this, 1, ""));
   624  };
   625  
   626  
   627  /**
   628   * @param {string} value
   629   * @return {!proto.keys.ListRequest} returns this
   630   */
   631  proto.keys.ListRequest.prototype.setKeyname = function(value) {
   632    return jspb.Message.setProto3StringField(this, 1, value);
   633  };
   634  
   635  
   636  
   637  
   638  
   639  if (jspb.Message.GENERATE_TO_OBJECT) {
   640  /**
   641   * Creates an object representation of this proto.
   642   * Field names that are reserved in JavaScript and will be renamed to pb_name.
   643   * Optional fields that are not set will be set to undefined.
   644   * To access a reserved field use, foo.pb_<name>, eg, foo.pb_default.
   645   * For the list of reserved names please see:
   646   *     net/proto2/compiler/js/internal/generator.cc#kKeyword.
   647   * @param {boolean=} opt_includeInstance Deprecated. whether to include the
   648   *     JSPB instance for transitional soy proto support:
   649   *     http://goto/soy-param-migration
   650   * @return {!Object}
   651   */
   652  proto.keys.VerifyResponse.prototype.toObject = function(opt_includeInstance) {
   653    return proto.keys.VerifyResponse.toObject(opt_includeInstance, this);
   654  };
   655  
   656  
   657  /**
   658   * Static version of the {@see toObject} method.
   659   * @param {boolean|undefined} includeInstance Deprecated. Whether to include
   660   *     the JSPB instance for transitional soy proto support:
   661   *     http://goto/soy-param-migration
   662   * @param {!proto.keys.VerifyResponse} msg The msg instance to transform.
   663   * @return {!Object}
   664   * @suppress {unusedLocalVariables} f is only used for nested messages
   665   */
   666  proto.keys.VerifyResponse.toObject = function(includeInstance, msg) {
   667    var f, obj = {
   668  
   669    };
   670  
   671    if (includeInstance) {
   672      obj.$jspbMessageInstance = msg;
   673    }
   674    return obj;
   675  };
   676  }
   677  
   678  
   679  /**
   680   * Deserializes binary data (in protobuf wire format).
   681   * @param {jspb.ByteSource} bytes The bytes to deserialize.
   682   * @return {!proto.keys.VerifyResponse}
   683   */
   684  proto.keys.VerifyResponse.deserializeBinary = function(bytes) {
   685    var reader = new jspb.BinaryReader(bytes);
   686    var msg = new proto.keys.VerifyResponse;
   687    return proto.keys.VerifyResponse.deserializeBinaryFromReader(msg, reader);
   688  };
   689  
   690  
   691  /**
   692   * Deserializes binary data (in protobuf wire format) from the
   693   * given reader into the given message object.
   694   * @param {!proto.keys.VerifyResponse} msg The message object to deserialize into.
   695   * @param {!jspb.BinaryReader} reader The BinaryReader to use.
   696   * @return {!proto.keys.VerifyResponse}
   697   */
   698  proto.keys.VerifyResponse.deserializeBinaryFromReader = function(msg, reader) {
   699    while (reader.nextField()) {
   700      if (reader.isEndGroup()) {
   701        break;
   702      }
   703      var field = reader.getFieldNumber();
   704      switch (field) {
   705      default:
   706        reader.skipField();
   707        break;
   708      }
   709    }
   710    return msg;
   711  };
   712  
   713  
   714  /**
   715   * Serializes the message to binary data (in protobuf wire format).
   716   * @return {!Uint8Array}
   717   */
   718  proto.keys.VerifyResponse.prototype.serializeBinary = function() {
   719    var writer = new jspb.BinaryWriter();
   720    proto.keys.VerifyResponse.serializeBinaryToWriter(this, writer);
   721    return writer.getResultBuffer();
   722  };
   723  
   724  
   725  /**
   726   * Serializes the given message to binary data (in protobuf wire
   727   * format), writing to the given BinaryWriter.
   728   * @param {!proto.keys.VerifyResponse} message
   729   * @param {!jspb.BinaryWriter} writer
   730   * @suppress {unusedLocalVariables} f is only used for nested messages
   731   */
   732  proto.keys.VerifyResponse.serializeBinaryToWriter = function(message, writer) {
   733    var f = undefined;
   734  };
   735  
   736  
   737  
   738  
   739  
   740  if (jspb.Message.GENERATE_TO_OBJECT) {
   741  /**
   742   * Creates an object representation of this proto.
   743   * Field names that are reserved in JavaScript and will be renamed to pb_name.
   744   * Optional fields that are not set will be set to undefined.
   745   * To access a reserved field use, foo.pb_<name>, eg, foo.pb_default.
   746   * For the list of reserved names please see:
   747   *     net/proto2/compiler/js/internal/generator.cc#kKeyword.
   748   * @param {boolean=} opt_includeInstance Deprecated. whether to include the
   749   *     JSPB instance for transitional soy proto support:
   750   *     http://goto/soy-param-migration
   751   * @return {!Object}
   752   */
   753  proto.keys.RemoveNameResponse.prototype.toObject = function(opt_includeInstance) {
   754    return proto.keys.RemoveNameResponse.toObject(opt_includeInstance, this);
   755  };
   756  
   757  
   758  /**
   759   * Static version of the {@see toObject} method.
   760   * @param {boolean|undefined} includeInstance Deprecated. Whether to include
   761   *     the JSPB instance for transitional soy proto support:
   762   *     http://goto/soy-param-migration
   763   * @param {!proto.keys.RemoveNameResponse} msg The msg instance to transform.
   764   * @return {!Object}
   765   * @suppress {unusedLocalVariables} f is only used for nested messages
   766   */
   767  proto.keys.RemoveNameResponse.toObject = function(includeInstance, msg) {
   768    var f, obj = {
   769  
   770    };
   771  
   772    if (includeInstance) {
   773      obj.$jspbMessageInstance = msg;
   774    }
   775    return obj;
   776  };
   777  }
   778  
   779  
   780  /**
   781   * Deserializes binary data (in protobuf wire format).
   782   * @param {jspb.ByteSource} bytes The bytes to deserialize.
   783   * @return {!proto.keys.RemoveNameResponse}
   784   */
   785  proto.keys.RemoveNameResponse.deserializeBinary = function(bytes) {
   786    var reader = new jspb.BinaryReader(bytes);
   787    var msg = new proto.keys.RemoveNameResponse;
   788    return proto.keys.RemoveNameResponse.deserializeBinaryFromReader(msg, reader);
   789  };
   790  
   791  
   792  /**
   793   * Deserializes binary data (in protobuf wire format) from the
   794   * given reader into the given message object.
   795   * @param {!proto.keys.RemoveNameResponse} msg The message object to deserialize into.
   796   * @param {!jspb.BinaryReader} reader The BinaryReader to use.
   797   * @return {!proto.keys.RemoveNameResponse}
   798   */
   799  proto.keys.RemoveNameResponse.deserializeBinaryFromReader = function(msg, reader) {
   800    while (reader.nextField()) {
   801      if (reader.isEndGroup()) {
   802        break;
   803      }
   804      var field = reader.getFieldNumber();
   805      switch (field) {
   806      default:
   807        reader.skipField();
   808        break;
   809      }
   810    }
   811    return msg;
   812  };
   813  
   814  
   815  /**
   816   * Serializes the message to binary data (in protobuf wire format).
   817   * @return {!Uint8Array}
   818   */
   819  proto.keys.RemoveNameResponse.prototype.serializeBinary = function() {
   820    var writer = new jspb.BinaryWriter();
   821    proto.keys.RemoveNameResponse.serializeBinaryToWriter(this, writer);
   822    return writer.getResultBuffer();
   823  };
   824  
   825  
   826  /**
   827   * Serializes the given message to binary data (in protobuf wire
   828   * format), writing to the given BinaryWriter.
   829   * @param {!proto.keys.RemoveNameResponse} message
   830   * @param {!jspb.BinaryWriter} writer
   831   * @suppress {unusedLocalVariables} f is only used for nested messages
   832   */
   833  proto.keys.RemoveNameResponse.serializeBinaryToWriter = function(message, writer) {
   834    var f = undefined;
   835  };
   836  
   837  
   838  
   839  
   840  
   841  if (jspb.Message.GENERATE_TO_OBJECT) {
   842  /**
   843   * Creates an object representation of this proto.
   844   * Field names that are reserved in JavaScript and will be renamed to pb_name.
   845   * Optional fields that are not set will be set to undefined.
   846   * To access a reserved field use, foo.pb_<name>, eg, foo.pb_default.
   847   * For the list of reserved names please see:
   848   *     net/proto2/compiler/js/internal/generator.cc#kKeyword.
   849   * @param {boolean=} opt_includeInstance Deprecated. whether to include the
   850   *     JSPB instance for transitional soy proto support:
   851   *     http://goto/soy-param-migration
   852   * @return {!Object}
   853   */
   854  proto.keys.AddNameResponse.prototype.toObject = function(opt_includeInstance) {
   855    return proto.keys.AddNameResponse.toObject(opt_includeInstance, this);
   856  };
   857  
   858  
   859  /**
   860   * Static version of the {@see toObject} method.
   861   * @param {boolean|undefined} includeInstance Deprecated. Whether to include
   862   *     the JSPB instance for transitional soy proto support:
   863   *     http://goto/soy-param-migration
   864   * @param {!proto.keys.AddNameResponse} msg The msg instance to transform.
   865   * @return {!Object}
   866   * @suppress {unusedLocalVariables} f is only used for nested messages
   867   */
   868  proto.keys.AddNameResponse.toObject = function(includeInstance, msg) {
   869    var f, obj = {
   870  
   871    };
   872  
   873    if (includeInstance) {
   874      obj.$jspbMessageInstance = msg;
   875    }
   876    return obj;
   877  };
   878  }
   879  
   880  
   881  /**
   882   * Deserializes binary data (in protobuf wire format).
   883   * @param {jspb.ByteSource} bytes The bytes to deserialize.
   884   * @return {!proto.keys.AddNameResponse}
   885   */
   886  proto.keys.AddNameResponse.deserializeBinary = function(bytes) {
   887    var reader = new jspb.BinaryReader(bytes);
   888    var msg = new proto.keys.AddNameResponse;
   889    return proto.keys.AddNameResponse.deserializeBinaryFromReader(msg, reader);
   890  };
   891  
   892  
   893  /**
   894   * Deserializes binary data (in protobuf wire format) from the
   895   * given reader into the given message object.
   896   * @param {!proto.keys.AddNameResponse} msg The message object to deserialize into.
   897   * @param {!jspb.BinaryReader} reader The BinaryReader to use.
   898   * @return {!proto.keys.AddNameResponse}
   899   */
   900  proto.keys.AddNameResponse.deserializeBinaryFromReader = function(msg, reader) {
   901    while (reader.nextField()) {
   902      if (reader.isEndGroup()) {
   903        break;
   904      }
   905      var field = reader.getFieldNumber();
   906      switch (field) {
   907      default:
   908        reader.skipField();
   909        break;
   910      }
   911    }
   912    return msg;
   913  };
   914  
   915  
   916  /**
   917   * Serializes the message to binary data (in protobuf wire format).
   918   * @return {!Uint8Array}
   919   */
   920  proto.keys.AddNameResponse.prototype.serializeBinary = function() {
   921    var writer = new jspb.BinaryWriter();
   922    proto.keys.AddNameResponse.serializeBinaryToWriter(this, writer);
   923    return writer.getResultBuffer();
   924  };
   925  
   926  
   927  /**
   928   * Serializes the given message to binary data (in protobuf wire
   929   * format), writing to the given BinaryWriter.
   930   * @param {!proto.keys.AddNameResponse} message
   931   * @param {!jspb.BinaryWriter} writer
   932   * @suppress {unusedLocalVariables} f is only used for nested messages
   933   */
   934  proto.keys.AddNameResponse.serializeBinaryToWriter = function(message, writer) {
   935    var f = undefined;
   936  };
   937  
   938  
   939  
   940  
   941  
   942  if (jspb.Message.GENERATE_TO_OBJECT) {
   943  /**
   944   * Creates an object representation of this proto.
   945   * Field names that are reserved in JavaScript and will be renamed to pb_name.
   946   * Optional fields that are not set will be set to undefined.
   947   * To access a reserved field use, foo.pb_<name>, eg, foo.pb_default.
   948   * For the list of reserved names please see:
   949   *     net/proto2/compiler/js/internal/generator.cc#kKeyword.
   950   * @param {boolean=} opt_includeInstance Deprecated. whether to include the
   951   *     JSPB instance for transitional soy proto support:
   952   *     http://goto/soy-param-migration
   953   * @return {!Object}
   954   */
   955  proto.keys.RemoveNameRequest.prototype.toObject = function(opt_includeInstance) {
   956    return proto.keys.RemoveNameRequest.toObject(opt_includeInstance, this);
   957  };
   958  
   959  
   960  /**
   961   * Static version of the {@see toObject} method.
   962   * @param {boolean|undefined} includeInstance Deprecated. Whether to include
   963   *     the JSPB instance for transitional soy proto support:
   964   *     http://goto/soy-param-migration
   965   * @param {!proto.keys.RemoveNameRequest} msg The msg instance to transform.
   966   * @return {!Object}
   967   * @suppress {unusedLocalVariables} f is only used for nested messages
   968   */
   969  proto.keys.RemoveNameRequest.toObject = function(includeInstance, msg) {
   970    var f, obj = {
   971      keyname: jspb.Message.getFieldWithDefault(msg, 1, "")
   972    };
   973  
   974    if (includeInstance) {
   975      obj.$jspbMessageInstance = msg;
   976    }
   977    return obj;
   978  };
   979  }
   980  
   981  
   982  /**
   983   * Deserializes binary data (in protobuf wire format).
   984   * @param {jspb.ByteSource} bytes The bytes to deserialize.
   985   * @return {!proto.keys.RemoveNameRequest}
   986   */
   987  proto.keys.RemoveNameRequest.deserializeBinary = function(bytes) {
   988    var reader = new jspb.BinaryReader(bytes);
   989    var msg = new proto.keys.RemoveNameRequest;
   990    return proto.keys.RemoveNameRequest.deserializeBinaryFromReader(msg, reader);
   991  };
   992  
   993  
   994  /**
   995   * Deserializes binary data (in protobuf wire format) from the
   996   * given reader into the given message object.
   997   * @param {!proto.keys.RemoveNameRequest} msg The message object to deserialize into.
   998   * @param {!jspb.BinaryReader} reader The BinaryReader to use.
   999   * @return {!proto.keys.RemoveNameRequest}
  1000   */
  1001  proto.keys.RemoveNameRequest.deserializeBinaryFromReader = function(msg, reader) {
  1002    while (reader.nextField()) {
  1003      if (reader.isEndGroup()) {
  1004        break;
  1005      }
  1006      var field = reader.getFieldNumber();
  1007      switch (field) {
  1008      case 1:
  1009        var value = /** @type {string} */ (reader.readString());
  1010        msg.setKeyname(value);
  1011        break;
  1012      default:
  1013        reader.skipField();
  1014        break;
  1015      }
  1016    }
  1017    return msg;
  1018  };
  1019  
  1020  
  1021  /**
  1022   * Serializes the message to binary data (in protobuf wire format).
  1023   * @return {!Uint8Array}
  1024   */
  1025  proto.keys.RemoveNameRequest.prototype.serializeBinary = function() {
  1026    var writer = new jspb.BinaryWriter();
  1027    proto.keys.RemoveNameRequest.serializeBinaryToWriter(this, writer);
  1028    return writer.getResultBuffer();
  1029  };
  1030  
  1031  
  1032  /**
  1033   * Serializes the given message to binary data (in protobuf wire
  1034   * format), writing to the given BinaryWriter.
  1035   * @param {!proto.keys.RemoveNameRequest} message
  1036   * @param {!jspb.BinaryWriter} writer
  1037   * @suppress {unusedLocalVariables} f is only used for nested messages
  1038   */
  1039  proto.keys.RemoveNameRequest.serializeBinaryToWriter = function(message, writer) {
  1040    var f = undefined;
  1041    f = message.getKeyname();
  1042    if (f.length > 0) {
  1043      writer.writeString(
  1044        1,
  1045        f
  1046      );
  1047    }
  1048  };
  1049  
  1050  
  1051  /**
  1052   * optional string KeyName = 1;
  1053   * @return {string}
  1054   */
  1055  proto.keys.RemoveNameRequest.prototype.getKeyname = function() {
  1056    return /** @type {string} */ (jspb.Message.getFieldWithDefault(this, 1, ""));
  1057  };
  1058  
  1059  
  1060  /**
  1061   * @param {string} value
  1062   * @return {!proto.keys.RemoveNameRequest} returns this
  1063   */
  1064  proto.keys.RemoveNameRequest.prototype.setKeyname = function(value) {
  1065    return jspb.Message.setProto3StringField(this, 1, value);
  1066  };
  1067  
  1068  
  1069  
  1070  
  1071  
  1072  if (jspb.Message.GENERATE_TO_OBJECT) {
  1073  /**
  1074   * Creates an object representation of this proto.
  1075   * Field names that are reserved in JavaScript and will be renamed to pb_name.
  1076   * Optional fields that are not set will be set to undefined.
  1077   * To access a reserved field use, foo.pb_<name>, eg, foo.pb_default.
  1078   * For the list of reserved names please see:
  1079   *     net/proto2/compiler/js/internal/generator.cc#kKeyword.
  1080   * @param {boolean=} opt_includeInstance Deprecated. whether to include the
  1081   *     JSPB instance for transitional soy proto support:
  1082   *     http://goto/soy-param-migration
  1083   * @return {!Object}
  1084   */
  1085  proto.keys.GenRequest.prototype.toObject = function(opt_includeInstance) {
  1086    return proto.keys.GenRequest.toObject(opt_includeInstance, this);
  1087  };
  1088  
  1089  
  1090  /**
  1091   * Static version of the {@see toObject} method.
  1092   * @param {boolean|undefined} includeInstance Deprecated. Whether to include
  1093   *     the JSPB instance for transitional soy proto support:
  1094   *     http://goto/soy-param-migration
  1095   * @param {!proto.keys.GenRequest} msg The msg instance to transform.
  1096   * @return {!Object}
  1097   * @suppress {unusedLocalVariables} f is only used for nested messages
  1098   */
  1099  proto.keys.GenRequest.toObject = function(includeInstance, msg) {
  1100    var f, obj = {
  1101      passphrase: jspb.Message.getFieldWithDefault(msg, 1, ""),
  1102      curvetype: jspb.Message.getFieldWithDefault(msg, 2, ""),
  1103      keyname: jspb.Message.getFieldWithDefault(msg, 3, "")
  1104    };
  1105  
  1106    if (includeInstance) {
  1107      obj.$jspbMessageInstance = msg;
  1108    }
  1109    return obj;
  1110  };
  1111  }
  1112  
  1113  
  1114  /**
  1115   * Deserializes binary data (in protobuf wire format).
  1116   * @param {jspb.ByteSource} bytes The bytes to deserialize.
  1117   * @return {!proto.keys.GenRequest}
  1118   */
  1119  proto.keys.GenRequest.deserializeBinary = function(bytes) {
  1120    var reader = new jspb.BinaryReader(bytes);
  1121    var msg = new proto.keys.GenRequest;
  1122    return proto.keys.GenRequest.deserializeBinaryFromReader(msg, reader);
  1123  };
  1124  
  1125  
  1126  /**
  1127   * Deserializes binary data (in protobuf wire format) from the
  1128   * given reader into the given message object.
  1129   * @param {!proto.keys.GenRequest} msg The message object to deserialize into.
  1130   * @param {!jspb.BinaryReader} reader The BinaryReader to use.
  1131   * @return {!proto.keys.GenRequest}
  1132   */
  1133  proto.keys.GenRequest.deserializeBinaryFromReader = function(msg, reader) {
  1134    while (reader.nextField()) {
  1135      if (reader.isEndGroup()) {
  1136        break;
  1137      }
  1138      var field = reader.getFieldNumber();
  1139      switch (field) {
  1140      case 1:
  1141        var value = /** @type {string} */ (reader.readString());
  1142        msg.setPassphrase(value);
  1143        break;
  1144      case 2:
  1145        var value = /** @type {string} */ (reader.readString());
  1146        msg.setCurvetype(value);
  1147        break;
  1148      case 3:
  1149        var value = /** @type {string} */ (reader.readString());
  1150        msg.setKeyname(value);
  1151        break;
  1152      default:
  1153        reader.skipField();
  1154        break;
  1155      }
  1156    }
  1157    return msg;
  1158  };
  1159  
  1160  
  1161  /**
  1162   * Serializes the message to binary data (in protobuf wire format).
  1163   * @return {!Uint8Array}
  1164   */
  1165  proto.keys.GenRequest.prototype.serializeBinary = function() {
  1166    var writer = new jspb.BinaryWriter();
  1167    proto.keys.GenRequest.serializeBinaryToWriter(this, writer);
  1168    return writer.getResultBuffer();
  1169  };
  1170  
  1171  
  1172  /**
  1173   * Serializes the given message to binary data (in protobuf wire
  1174   * format), writing to the given BinaryWriter.
  1175   * @param {!proto.keys.GenRequest} message
  1176   * @param {!jspb.BinaryWriter} writer
  1177   * @suppress {unusedLocalVariables} f is only used for nested messages
  1178   */
  1179  proto.keys.GenRequest.serializeBinaryToWriter = function(message, writer) {
  1180    var f = undefined;
  1181    f = message.getPassphrase();
  1182    if (f.length > 0) {
  1183      writer.writeString(
  1184        1,
  1185        f
  1186      );
  1187    }
  1188    f = message.getCurvetype();
  1189    if (f.length > 0) {
  1190      writer.writeString(
  1191        2,
  1192        f
  1193      );
  1194    }
  1195    f = message.getKeyname();
  1196    if (f.length > 0) {
  1197      writer.writeString(
  1198        3,
  1199        f
  1200      );
  1201    }
  1202  };
  1203  
  1204  
  1205  /**
  1206   * optional string Passphrase = 1;
  1207   * @return {string}
  1208   */
  1209  proto.keys.GenRequest.prototype.getPassphrase = function() {
  1210    return /** @type {string} */ (jspb.Message.getFieldWithDefault(this, 1, ""));
  1211  };
  1212  
  1213  
  1214  /**
  1215   * @param {string} value
  1216   * @return {!proto.keys.GenRequest} returns this
  1217   */
  1218  proto.keys.GenRequest.prototype.setPassphrase = function(value) {
  1219    return jspb.Message.setProto3StringField(this, 1, value);
  1220  };
  1221  
  1222  
  1223  /**
  1224   * optional string CurveType = 2;
  1225   * @return {string}
  1226   */
  1227  proto.keys.GenRequest.prototype.getCurvetype = function() {
  1228    return /** @type {string} */ (jspb.Message.getFieldWithDefault(this, 2, ""));
  1229  };
  1230  
  1231  
  1232  /**
  1233   * @param {string} value
  1234   * @return {!proto.keys.GenRequest} returns this
  1235   */
  1236  proto.keys.GenRequest.prototype.setCurvetype = function(value) {
  1237    return jspb.Message.setProto3StringField(this, 2, value);
  1238  };
  1239  
  1240  
  1241  /**
  1242   * optional string KeyName = 3;
  1243   * @return {string}
  1244   */
  1245  proto.keys.GenRequest.prototype.getKeyname = function() {
  1246    return /** @type {string} */ (jspb.Message.getFieldWithDefault(this, 3, ""));
  1247  };
  1248  
  1249  
  1250  /**
  1251   * @param {string} value
  1252   * @return {!proto.keys.GenRequest} returns this
  1253   */
  1254  proto.keys.GenRequest.prototype.setKeyname = function(value) {
  1255    return jspb.Message.setProto3StringField(this, 3, value);
  1256  };
  1257  
  1258  
  1259  
  1260  
  1261  
  1262  if (jspb.Message.GENERATE_TO_OBJECT) {
  1263  /**
  1264   * Creates an object representation of this proto.
  1265   * Field names that are reserved in JavaScript and will be renamed to pb_name.
  1266   * Optional fields that are not set will be set to undefined.
  1267   * To access a reserved field use, foo.pb_<name>, eg, foo.pb_default.
  1268   * For the list of reserved names please see:
  1269   *     net/proto2/compiler/js/internal/generator.cc#kKeyword.
  1270   * @param {boolean=} opt_includeInstance Deprecated. whether to include the
  1271   *     JSPB instance for transitional soy proto support:
  1272   *     http://goto/soy-param-migration
  1273   * @return {!Object}
  1274   */
  1275  proto.keys.GenResponse.prototype.toObject = function(opt_includeInstance) {
  1276    return proto.keys.GenResponse.toObject(opt_includeInstance, this);
  1277  };
  1278  
  1279  
  1280  /**
  1281   * Static version of the {@see toObject} method.
  1282   * @param {boolean|undefined} includeInstance Deprecated. Whether to include
  1283   *     the JSPB instance for transitional soy proto support:
  1284   *     http://goto/soy-param-migration
  1285   * @param {!proto.keys.GenResponse} msg The msg instance to transform.
  1286   * @return {!Object}
  1287   * @suppress {unusedLocalVariables} f is only used for nested messages
  1288   */
  1289  proto.keys.GenResponse.toObject = function(includeInstance, msg) {
  1290    var f, obj = {
  1291      address: jspb.Message.getFieldWithDefault(msg, 1, "")
  1292    };
  1293  
  1294    if (includeInstance) {
  1295      obj.$jspbMessageInstance = msg;
  1296    }
  1297    return obj;
  1298  };
  1299  }
  1300  
  1301  
  1302  /**
  1303   * Deserializes binary data (in protobuf wire format).
  1304   * @param {jspb.ByteSource} bytes The bytes to deserialize.
  1305   * @return {!proto.keys.GenResponse}
  1306   */
  1307  proto.keys.GenResponse.deserializeBinary = function(bytes) {
  1308    var reader = new jspb.BinaryReader(bytes);
  1309    var msg = new proto.keys.GenResponse;
  1310    return proto.keys.GenResponse.deserializeBinaryFromReader(msg, reader);
  1311  };
  1312  
  1313  
  1314  /**
  1315   * Deserializes binary data (in protobuf wire format) from the
  1316   * given reader into the given message object.
  1317   * @param {!proto.keys.GenResponse} msg The message object to deserialize into.
  1318   * @param {!jspb.BinaryReader} reader The BinaryReader to use.
  1319   * @return {!proto.keys.GenResponse}
  1320   */
  1321  proto.keys.GenResponse.deserializeBinaryFromReader = function(msg, reader) {
  1322    while (reader.nextField()) {
  1323      if (reader.isEndGroup()) {
  1324        break;
  1325      }
  1326      var field = reader.getFieldNumber();
  1327      switch (field) {
  1328      case 1:
  1329        var value = /** @type {string} */ (reader.readString());
  1330        msg.setAddress(value);
  1331        break;
  1332      default:
  1333        reader.skipField();
  1334        break;
  1335      }
  1336    }
  1337    return msg;
  1338  };
  1339  
  1340  
  1341  /**
  1342   * Serializes the message to binary data (in protobuf wire format).
  1343   * @return {!Uint8Array}
  1344   */
  1345  proto.keys.GenResponse.prototype.serializeBinary = function() {
  1346    var writer = new jspb.BinaryWriter();
  1347    proto.keys.GenResponse.serializeBinaryToWriter(this, writer);
  1348    return writer.getResultBuffer();
  1349  };
  1350  
  1351  
  1352  /**
  1353   * Serializes the given message to binary data (in protobuf wire
  1354   * format), writing to the given BinaryWriter.
  1355   * @param {!proto.keys.GenResponse} message
  1356   * @param {!jspb.BinaryWriter} writer
  1357   * @suppress {unusedLocalVariables} f is only used for nested messages
  1358   */
  1359  proto.keys.GenResponse.serializeBinaryToWriter = function(message, writer) {
  1360    var f = undefined;
  1361    f = message.getAddress();
  1362    if (f.length > 0) {
  1363      writer.writeString(
  1364        1,
  1365        f
  1366      );
  1367    }
  1368  };
  1369  
  1370  
  1371  /**
  1372   * optional string Address = 1;
  1373   * @return {string}
  1374   */
  1375  proto.keys.GenResponse.prototype.getAddress = function() {
  1376    return /** @type {string} */ (jspb.Message.getFieldWithDefault(this, 1, ""));
  1377  };
  1378  
  1379  
  1380  /**
  1381   * @param {string} value
  1382   * @return {!proto.keys.GenResponse} returns this
  1383   */
  1384  proto.keys.GenResponse.prototype.setAddress = function(value) {
  1385    return jspb.Message.setProto3StringField(this, 1, value);
  1386  };
  1387  
  1388  
  1389  
  1390  
  1391  
  1392  if (jspb.Message.GENERATE_TO_OBJECT) {
  1393  /**
  1394   * Creates an object representation of this proto.
  1395   * Field names that are reserved in JavaScript and will be renamed to pb_name.
  1396   * Optional fields that are not set will be set to undefined.
  1397   * To access a reserved field use, foo.pb_<name>, eg, foo.pb_default.
  1398   * For the list of reserved names please see:
  1399   *     net/proto2/compiler/js/internal/generator.cc#kKeyword.
  1400   * @param {boolean=} opt_includeInstance Deprecated. whether to include the
  1401   *     JSPB instance for transitional soy proto support:
  1402   *     http://goto/soy-param-migration
  1403   * @return {!Object}
  1404   */
  1405  proto.keys.PubRequest.prototype.toObject = function(opt_includeInstance) {
  1406    return proto.keys.PubRequest.toObject(opt_includeInstance, this);
  1407  };
  1408  
  1409  
  1410  /**
  1411   * Static version of the {@see toObject} method.
  1412   * @param {boolean|undefined} includeInstance Deprecated. Whether to include
  1413   *     the JSPB instance for transitional soy proto support:
  1414   *     http://goto/soy-param-migration
  1415   * @param {!proto.keys.PubRequest} msg The msg instance to transform.
  1416   * @return {!Object}
  1417   * @suppress {unusedLocalVariables} f is only used for nested messages
  1418   */
  1419  proto.keys.PubRequest.toObject = function(includeInstance, msg) {
  1420    var f, obj = {
  1421      address: jspb.Message.getFieldWithDefault(msg, 1, ""),
  1422      name: jspb.Message.getFieldWithDefault(msg, 2, "")
  1423    };
  1424  
  1425    if (includeInstance) {
  1426      obj.$jspbMessageInstance = msg;
  1427    }
  1428    return obj;
  1429  };
  1430  }
  1431  
  1432  
  1433  /**
  1434   * Deserializes binary data (in protobuf wire format).
  1435   * @param {jspb.ByteSource} bytes The bytes to deserialize.
  1436   * @return {!proto.keys.PubRequest}
  1437   */
  1438  proto.keys.PubRequest.deserializeBinary = function(bytes) {
  1439    var reader = new jspb.BinaryReader(bytes);
  1440    var msg = new proto.keys.PubRequest;
  1441    return proto.keys.PubRequest.deserializeBinaryFromReader(msg, reader);
  1442  };
  1443  
  1444  
  1445  /**
  1446   * Deserializes binary data (in protobuf wire format) from the
  1447   * given reader into the given message object.
  1448   * @param {!proto.keys.PubRequest} msg The message object to deserialize into.
  1449   * @param {!jspb.BinaryReader} reader The BinaryReader to use.
  1450   * @return {!proto.keys.PubRequest}
  1451   */
  1452  proto.keys.PubRequest.deserializeBinaryFromReader = function(msg, reader) {
  1453    while (reader.nextField()) {
  1454      if (reader.isEndGroup()) {
  1455        break;
  1456      }
  1457      var field = reader.getFieldNumber();
  1458      switch (field) {
  1459      case 1:
  1460        var value = /** @type {string} */ (reader.readString());
  1461        msg.setAddress(value);
  1462        break;
  1463      case 2:
  1464        var value = /** @type {string} */ (reader.readString());
  1465        msg.setName(value);
  1466        break;
  1467      default:
  1468        reader.skipField();
  1469        break;
  1470      }
  1471    }
  1472    return msg;
  1473  };
  1474  
  1475  
  1476  /**
  1477   * Serializes the message to binary data (in protobuf wire format).
  1478   * @return {!Uint8Array}
  1479   */
  1480  proto.keys.PubRequest.prototype.serializeBinary = function() {
  1481    var writer = new jspb.BinaryWriter();
  1482    proto.keys.PubRequest.serializeBinaryToWriter(this, writer);
  1483    return writer.getResultBuffer();
  1484  };
  1485  
  1486  
  1487  /**
  1488   * Serializes the given message to binary data (in protobuf wire
  1489   * format), writing to the given BinaryWriter.
  1490   * @param {!proto.keys.PubRequest} message
  1491   * @param {!jspb.BinaryWriter} writer
  1492   * @suppress {unusedLocalVariables} f is only used for nested messages
  1493   */
  1494  proto.keys.PubRequest.serializeBinaryToWriter = function(message, writer) {
  1495    var f = undefined;
  1496    f = message.getAddress();
  1497    if (f.length > 0) {
  1498      writer.writeString(
  1499        1,
  1500        f
  1501      );
  1502    }
  1503    f = message.getName();
  1504    if (f.length > 0) {
  1505      writer.writeString(
  1506        2,
  1507        f
  1508      );
  1509    }
  1510  };
  1511  
  1512  
  1513  /**
  1514   * optional string Address = 1;
  1515   * @return {string}
  1516   */
  1517  proto.keys.PubRequest.prototype.getAddress = function() {
  1518    return /** @type {string} */ (jspb.Message.getFieldWithDefault(this, 1, ""));
  1519  };
  1520  
  1521  
  1522  /**
  1523   * @param {string} value
  1524   * @return {!proto.keys.PubRequest} returns this
  1525   */
  1526  proto.keys.PubRequest.prototype.setAddress = function(value) {
  1527    return jspb.Message.setProto3StringField(this, 1, value);
  1528  };
  1529  
  1530  
  1531  /**
  1532   * optional string Name = 2;
  1533   * @return {string}
  1534   */
  1535  proto.keys.PubRequest.prototype.getName = function() {
  1536    return /** @type {string} */ (jspb.Message.getFieldWithDefault(this, 2, ""));
  1537  };
  1538  
  1539  
  1540  /**
  1541   * @param {string} value
  1542   * @return {!proto.keys.PubRequest} returns this
  1543   */
  1544  proto.keys.PubRequest.prototype.setName = function(value) {
  1545    return jspb.Message.setProto3StringField(this, 2, value);
  1546  };
  1547  
  1548  
  1549  
  1550  
  1551  
  1552  if (jspb.Message.GENERATE_TO_OBJECT) {
  1553  /**
  1554   * Creates an object representation of this proto.
  1555   * Field names that are reserved in JavaScript and will be renamed to pb_name.
  1556   * Optional fields that are not set will be set to undefined.
  1557   * To access a reserved field use, foo.pb_<name>, eg, foo.pb_default.
  1558   * For the list of reserved names please see:
  1559   *     net/proto2/compiler/js/internal/generator.cc#kKeyword.
  1560   * @param {boolean=} opt_includeInstance Deprecated. whether to include the
  1561   *     JSPB instance for transitional soy proto support:
  1562   *     http://goto/soy-param-migration
  1563   * @return {!Object}
  1564   */
  1565  proto.keys.PubResponse.prototype.toObject = function(opt_includeInstance) {
  1566    return proto.keys.PubResponse.toObject(opt_includeInstance, this);
  1567  };
  1568  
  1569  
  1570  /**
  1571   * Static version of the {@see toObject} method.
  1572   * @param {boolean|undefined} includeInstance Deprecated. Whether to include
  1573   *     the JSPB instance for transitional soy proto support:
  1574   *     http://goto/soy-param-migration
  1575   * @param {!proto.keys.PubResponse} msg The msg instance to transform.
  1576   * @return {!Object}
  1577   * @suppress {unusedLocalVariables} f is only used for nested messages
  1578   */
  1579  proto.keys.PubResponse.toObject = function(includeInstance, msg) {
  1580    var f, obj = {
  1581      publickey: msg.getPublickey_asB64(),
  1582      curvetype: jspb.Message.getFieldWithDefault(msg, 2, "")
  1583    };
  1584  
  1585    if (includeInstance) {
  1586      obj.$jspbMessageInstance = msg;
  1587    }
  1588    return obj;
  1589  };
  1590  }
  1591  
  1592  
  1593  /**
  1594   * Deserializes binary data (in protobuf wire format).
  1595   * @param {jspb.ByteSource} bytes The bytes to deserialize.
  1596   * @return {!proto.keys.PubResponse}
  1597   */
  1598  proto.keys.PubResponse.deserializeBinary = function(bytes) {
  1599    var reader = new jspb.BinaryReader(bytes);
  1600    var msg = new proto.keys.PubResponse;
  1601    return proto.keys.PubResponse.deserializeBinaryFromReader(msg, reader);
  1602  };
  1603  
  1604  
  1605  /**
  1606   * Deserializes binary data (in protobuf wire format) from the
  1607   * given reader into the given message object.
  1608   * @param {!proto.keys.PubResponse} msg The message object to deserialize into.
  1609   * @param {!jspb.BinaryReader} reader The BinaryReader to use.
  1610   * @return {!proto.keys.PubResponse}
  1611   */
  1612  proto.keys.PubResponse.deserializeBinaryFromReader = function(msg, reader) {
  1613    while (reader.nextField()) {
  1614      if (reader.isEndGroup()) {
  1615        break;
  1616      }
  1617      var field = reader.getFieldNumber();
  1618      switch (field) {
  1619      case 1:
  1620        var value = /** @type {!Uint8Array} */ (reader.readBytes());
  1621        msg.setPublickey(value);
  1622        break;
  1623      case 2:
  1624        var value = /** @type {string} */ (reader.readString());
  1625        msg.setCurvetype(value);
  1626        break;
  1627      default:
  1628        reader.skipField();
  1629        break;
  1630      }
  1631    }
  1632    return msg;
  1633  };
  1634  
  1635  
  1636  /**
  1637   * Serializes the message to binary data (in protobuf wire format).
  1638   * @return {!Uint8Array}
  1639   */
  1640  proto.keys.PubResponse.prototype.serializeBinary = function() {
  1641    var writer = new jspb.BinaryWriter();
  1642    proto.keys.PubResponse.serializeBinaryToWriter(this, writer);
  1643    return writer.getResultBuffer();
  1644  };
  1645  
  1646  
  1647  /**
  1648   * Serializes the given message to binary data (in protobuf wire
  1649   * format), writing to the given BinaryWriter.
  1650   * @param {!proto.keys.PubResponse} message
  1651   * @param {!jspb.BinaryWriter} writer
  1652   * @suppress {unusedLocalVariables} f is only used for nested messages
  1653   */
  1654  proto.keys.PubResponse.serializeBinaryToWriter = function(message, writer) {
  1655    var f = undefined;
  1656    f = message.getPublickey_asU8();
  1657    if (f.length > 0) {
  1658      writer.writeBytes(
  1659        1,
  1660        f
  1661      );
  1662    }
  1663    f = message.getCurvetype();
  1664    if (f.length > 0) {
  1665      writer.writeString(
  1666        2,
  1667        f
  1668      );
  1669    }
  1670  };
  1671  
  1672  
  1673  /**
  1674   * optional bytes PublicKey = 1;
  1675   * @return {!(string|Uint8Array)}
  1676   */
  1677  proto.keys.PubResponse.prototype.getPublickey = function() {
  1678    return /** @type {!(string|Uint8Array)} */ (jspb.Message.getFieldWithDefault(this, 1, ""));
  1679  };
  1680  
  1681  
  1682  /**
  1683   * optional bytes PublicKey = 1;
  1684   * This is a type-conversion wrapper around `getPublickey()`
  1685   * @return {string}
  1686   */
  1687  proto.keys.PubResponse.prototype.getPublickey_asB64 = function() {
  1688    return /** @type {string} */ (jspb.Message.bytesAsB64(
  1689        this.getPublickey()));
  1690  };
  1691  
  1692  
  1693  /**
  1694   * optional bytes PublicKey = 1;
  1695   * Note that Uint8Array is not supported on all browsers.
  1696   * @see http://caniuse.com/Uint8Array
  1697   * This is a type-conversion wrapper around `getPublickey()`
  1698   * @return {!Uint8Array}
  1699   */
  1700  proto.keys.PubResponse.prototype.getPublickey_asU8 = function() {
  1701    return /** @type {!Uint8Array} */ (jspb.Message.bytesAsU8(
  1702        this.getPublickey()));
  1703  };
  1704  
  1705  
  1706  /**
  1707   * @param {!(string|Uint8Array)} value
  1708   * @return {!proto.keys.PubResponse} returns this
  1709   */
  1710  proto.keys.PubResponse.prototype.setPublickey = function(value) {
  1711    return jspb.Message.setProto3BytesField(this, 1, value);
  1712  };
  1713  
  1714  
  1715  /**
  1716   * optional string CurveType = 2;
  1717   * @return {string}
  1718   */
  1719  proto.keys.PubResponse.prototype.getCurvetype = function() {
  1720    return /** @type {string} */ (jspb.Message.getFieldWithDefault(this, 2, ""));
  1721  };
  1722  
  1723  
  1724  /**
  1725   * @param {string} value
  1726   * @return {!proto.keys.PubResponse} returns this
  1727   */
  1728  proto.keys.PubResponse.prototype.setCurvetype = function(value) {
  1729    return jspb.Message.setProto3StringField(this, 2, value);
  1730  };
  1731  
  1732  
  1733  
  1734  
  1735  
  1736  if (jspb.Message.GENERATE_TO_OBJECT) {
  1737  /**
  1738   * Creates an object representation of this proto.
  1739   * Field names that are reserved in JavaScript and will be renamed to pb_name.
  1740   * Optional fields that are not set will be set to undefined.
  1741   * To access a reserved field use, foo.pb_<name>, eg, foo.pb_default.
  1742   * For the list of reserved names please see:
  1743   *     net/proto2/compiler/js/internal/generator.cc#kKeyword.
  1744   * @param {boolean=} opt_includeInstance Deprecated. whether to include the
  1745   *     JSPB instance for transitional soy proto support:
  1746   *     http://goto/soy-param-migration
  1747   * @return {!Object}
  1748   */
  1749  proto.keys.ImportJSONRequest.prototype.toObject = function(opt_includeInstance) {
  1750    return proto.keys.ImportJSONRequest.toObject(opt_includeInstance, this);
  1751  };
  1752  
  1753  
  1754  /**
  1755   * Static version of the {@see toObject} method.
  1756   * @param {boolean|undefined} includeInstance Deprecated. Whether to include
  1757   *     the JSPB instance for transitional soy proto support:
  1758   *     http://goto/soy-param-migration
  1759   * @param {!proto.keys.ImportJSONRequest} msg The msg instance to transform.
  1760   * @return {!Object}
  1761   * @suppress {unusedLocalVariables} f is only used for nested messages
  1762   */
  1763  proto.keys.ImportJSONRequest.toObject = function(includeInstance, msg) {
  1764    var f, obj = {
  1765      passphrase: jspb.Message.getFieldWithDefault(msg, 1, ""),
  1766      json: jspb.Message.getFieldWithDefault(msg, 2, "")
  1767    };
  1768  
  1769    if (includeInstance) {
  1770      obj.$jspbMessageInstance = msg;
  1771    }
  1772    return obj;
  1773  };
  1774  }
  1775  
  1776  
  1777  /**
  1778   * Deserializes binary data (in protobuf wire format).
  1779   * @param {jspb.ByteSource} bytes The bytes to deserialize.
  1780   * @return {!proto.keys.ImportJSONRequest}
  1781   */
  1782  proto.keys.ImportJSONRequest.deserializeBinary = function(bytes) {
  1783    var reader = new jspb.BinaryReader(bytes);
  1784    var msg = new proto.keys.ImportJSONRequest;
  1785    return proto.keys.ImportJSONRequest.deserializeBinaryFromReader(msg, reader);
  1786  };
  1787  
  1788  
  1789  /**
  1790   * Deserializes binary data (in protobuf wire format) from the
  1791   * given reader into the given message object.
  1792   * @param {!proto.keys.ImportJSONRequest} msg The message object to deserialize into.
  1793   * @param {!jspb.BinaryReader} reader The BinaryReader to use.
  1794   * @return {!proto.keys.ImportJSONRequest}
  1795   */
  1796  proto.keys.ImportJSONRequest.deserializeBinaryFromReader = function(msg, reader) {
  1797    while (reader.nextField()) {
  1798      if (reader.isEndGroup()) {
  1799        break;
  1800      }
  1801      var field = reader.getFieldNumber();
  1802      switch (field) {
  1803      case 1:
  1804        var value = /** @type {string} */ (reader.readString());
  1805        msg.setPassphrase(value);
  1806        break;
  1807      case 2:
  1808        var value = /** @type {string} */ (reader.readString());
  1809        msg.setJson(value);
  1810        break;
  1811      default:
  1812        reader.skipField();
  1813        break;
  1814      }
  1815    }
  1816    return msg;
  1817  };
  1818  
  1819  
  1820  /**
  1821   * Serializes the message to binary data (in protobuf wire format).
  1822   * @return {!Uint8Array}
  1823   */
  1824  proto.keys.ImportJSONRequest.prototype.serializeBinary = function() {
  1825    var writer = new jspb.BinaryWriter();
  1826    proto.keys.ImportJSONRequest.serializeBinaryToWriter(this, writer);
  1827    return writer.getResultBuffer();
  1828  };
  1829  
  1830  
  1831  /**
  1832   * Serializes the given message to binary data (in protobuf wire
  1833   * format), writing to the given BinaryWriter.
  1834   * @param {!proto.keys.ImportJSONRequest} message
  1835   * @param {!jspb.BinaryWriter} writer
  1836   * @suppress {unusedLocalVariables} f is only used for nested messages
  1837   */
  1838  proto.keys.ImportJSONRequest.serializeBinaryToWriter = function(message, writer) {
  1839    var f = undefined;
  1840    f = message.getPassphrase();
  1841    if (f.length > 0) {
  1842      writer.writeString(
  1843        1,
  1844        f
  1845      );
  1846    }
  1847    f = message.getJson();
  1848    if (f.length > 0) {
  1849      writer.writeString(
  1850        2,
  1851        f
  1852      );
  1853    }
  1854  };
  1855  
  1856  
  1857  /**
  1858   * optional string Passphrase = 1;
  1859   * @return {string}
  1860   */
  1861  proto.keys.ImportJSONRequest.prototype.getPassphrase = function() {
  1862    return /** @type {string} */ (jspb.Message.getFieldWithDefault(this, 1, ""));
  1863  };
  1864  
  1865  
  1866  /**
  1867   * @param {string} value
  1868   * @return {!proto.keys.ImportJSONRequest} returns this
  1869   */
  1870  proto.keys.ImportJSONRequest.prototype.setPassphrase = function(value) {
  1871    return jspb.Message.setProto3StringField(this, 1, value);
  1872  };
  1873  
  1874  
  1875  /**
  1876   * optional string JSON = 2;
  1877   * @return {string}
  1878   */
  1879  proto.keys.ImportJSONRequest.prototype.getJson = function() {
  1880    return /** @type {string} */ (jspb.Message.getFieldWithDefault(this, 2, ""));
  1881  };
  1882  
  1883  
  1884  /**
  1885   * @param {string} value
  1886   * @return {!proto.keys.ImportJSONRequest} returns this
  1887   */
  1888  proto.keys.ImportJSONRequest.prototype.setJson = function(value) {
  1889    return jspb.Message.setProto3StringField(this, 2, value);
  1890  };
  1891  
  1892  
  1893  
  1894  
  1895  
  1896  if (jspb.Message.GENERATE_TO_OBJECT) {
  1897  /**
  1898   * Creates an object representation of this proto.
  1899   * Field names that are reserved in JavaScript and will be renamed to pb_name.
  1900   * Optional fields that are not set will be set to undefined.
  1901   * To access a reserved field use, foo.pb_<name>, eg, foo.pb_default.
  1902   * For the list of reserved names please see:
  1903   *     net/proto2/compiler/js/internal/generator.cc#kKeyword.
  1904   * @param {boolean=} opt_includeInstance Deprecated. whether to include the
  1905   *     JSPB instance for transitional soy proto support:
  1906   *     http://goto/soy-param-migration
  1907   * @return {!Object}
  1908   */
  1909  proto.keys.ImportResponse.prototype.toObject = function(opt_includeInstance) {
  1910    return proto.keys.ImportResponse.toObject(opt_includeInstance, this);
  1911  };
  1912  
  1913  
  1914  /**
  1915   * Static version of the {@see toObject} method.
  1916   * @param {boolean|undefined} includeInstance Deprecated. Whether to include
  1917   *     the JSPB instance for transitional soy proto support:
  1918   *     http://goto/soy-param-migration
  1919   * @param {!proto.keys.ImportResponse} msg The msg instance to transform.
  1920   * @return {!Object}
  1921   * @suppress {unusedLocalVariables} f is only used for nested messages
  1922   */
  1923  proto.keys.ImportResponse.toObject = function(includeInstance, msg) {
  1924    var f, obj = {
  1925      address: jspb.Message.getFieldWithDefault(msg, 1, "")
  1926    };
  1927  
  1928    if (includeInstance) {
  1929      obj.$jspbMessageInstance = msg;
  1930    }
  1931    return obj;
  1932  };
  1933  }
  1934  
  1935  
  1936  /**
  1937   * Deserializes binary data (in protobuf wire format).
  1938   * @param {jspb.ByteSource} bytes The bytes to deserialize.
  1939   * @return {!proto.keys.ImportResponse}
  1940   */
  1941  proto.keys.ImportResponse.deserializeBinary = function(bytes) {
  1942    var reader = new jspb.BinaryReader(bytes);
  1943    var msg = new proto.keys.ImportResponse;
  1944    return proto.keys.ImportResponse.deserializeBinaryFromReader(msg, reader);
  1945  };
  1946  
  1947  
  1948  /**
  1949   * Deserializes binary data (in protobuf wire format) from the
  1950   * given reader into the given message object.
  1951   * @param {!proto.keys.ImportResponse} msg The message object to deserialize into.
  1952   * @param {!jspb.BinaryReader} reader The BinaryReader to use.
  1953   * @return {!proto.keys.ImportResponse}
  1954   */
  1955  proto.keys.ImportResponse.deserializeBinaryFromReader = function(msg, reader) {
  1956    while (reader.nextField()) {
  1957      if (reader.isEndGroup()) {
  1958        break;
  1959      }
  1960      var field = reader.getFieldNumber();
  1961      switch (field) {
  1962      case 1:
  1963        var value = /** @type {string} */ (reader.readString());
  1964        msg.setAddress(value);
  1965        break;
  1966      default:
  1967        reader.skipField();
  1968        break;
  1969      }
  1970    }
  1971    return msg;
  1972  };
  1973  
  1974  
  1975  /**
  1976   * Serializes the message to binary data (in protobuf wire format).
  1977   * @return {!Uint8Array}
  1978   */
  1979  proto.keys.ImportResponse.prototype.serializeBinary = function() {
  1980    var writer = new jspb.BinaryWriter();
  1981    proto.keys.ImportResponse.serializeBinaryToWriter(this, writer);
  1982    return writer.getResultBuffer();
  1983  };
  1984  
  1985  
  1986  /**
  1987   * Serializes the given message to binary data (in protobuf wire
  1988   * format), writing to the given BinaryWriter.
  1989   * @param {!proto.keys.ImportResponse} message
  1990   * @param {!jspb.BinaryWriter} writer
  1991   * @suppress {unusedLocalVariables} f is only used for nested messages
  1992   */
  1993  proto.keys.ImportResponse.serializeBinaryToWriter = function(message, writer) {
  1994    var f = undefined;
  1995    f = message.getAddress();
  1996    if (f.length > 0) {
  1997      writer.writeString(
  1998        1,
  1999        f
  2000      );
  2001    }
  2002  };
  2003  
  2004  
  2005  /**
  2006   * optional string Address = 1;
  2007   * @return {string}
  2008   */
  2009  proto.keys.ImportResponse.prototype.getAddress = function() {
  2010    return /** @type {string} */ (jspb.Message.getFieldWithDefault(this, 1, ""));
  2011  };
  2012  
  2013  
  2014  /**
  2015   * @param {string} value
  2016   * @return {!proto.keys.ImportResponse} returns this
  2017   */
  2018  proto.keys.ImportResponse.prototype.setAddress = function(value) {
  2019    return jspb.Message.setProto3StringField(this, 1, value);
  2020  };
  2021  
  2022  
  2023  
  2024  
  2025  
  2026  if (jspb.Message.GENERATE_TO_OBJECT) {
  2027  /**
  2028   * Creates an object representation of this proto.
  2029   * Field names that are reserved in JavaScript and will be renamed to pb_name.
  2030   * Optional fields that are not set will be set to undefined.
  2031   * To access a reserved field use, foo.pb_<name>, eg, foo.pb_default.
  2032   * For the list of reserved names please see:
  2033   *     net/proto2/compiler/js/internal/generator.cc#kKeyword.
  2034   * @param {boolean=} opt_includeInstance Deprecated. whether to include the
  2035   *     JSPB instance for transitional soy proto support:
  2036   *     http://goto/soy-param-migration
  2037   * @return {!Object}
  2038   */
  2039  proto.keys.ImportRequest.prototype.toObject = function(opt_includeInstance) {
  2040    return proto.keys.ImportRequest.toObject(opt_includeInstance, this);
  2041  };
  2042  
  2043  
  2044  /**
  2045   * Static version of the {@see toObject} method.
  2046   * @param {boolean|undefined} includeInstance Deprecated. Whether to include
  2047   *     the JSPB instance for transitional soy proto support:
  2048   *     http://goto/soy-param-migration
  2049   * @param {!proto.keys.ImportRequest} msg The msg instance to transform.
  2050   * @return {!Object}
  2051   * @suppress {unusedLocalVariables} f is only used for nested messages
  2052   */
  2053  proto.keys.ImportRequest.toObject = function(includeInstance, msg) {
  2054    var f, obj = {
  2055      passphrase: jspb.Message.getFieldWithDefault(msg, 1, ""),
  2056      name: jspb.Message.getFieldWithDefault(msg, 2, ""),
  2057      curvetype: jspb.Message.getFieldWithDefault(msg, 3, ""),
  2058      keybytes: msg.getKeybytes_asB64()
  2059    };
  2060  
  2061    if (includeInstance) {
  2062      obj.$jspbMessageInstance = msg;
  2063    }
  2064    return obj;
  2065  };
  2066  }
  2067  
  2068  
  2069  /**
  2070   * Deserializes binary data (in protobuf wire format).
  2071   * @param {jspb.ByteSource} bytes The bytes to deserialize.
  2072   * @return {!proto.keys.ImportRequest}
  2073   */
  2074  proto.keys.ImportRequest.deserializeBinary = function(bytes) {
  2075    var reader = new jspb.BinaryReader(bytes);
  2076    var msg = new proto.keys.ImportRequest;
  2077    return proto.keys.ImportRequest.deserializeBinaryFromReader(msg, reader);
  2078  };
  2079  
  2080  
  2081  /**
  2082   * Deserializes binary data (in protobuf wire format) from the
  2083   * given reader into the given message object.
  2084   * @param {!proto.keys.ImportRequest} msg The message object to deserialize into.
  2085   * @param {!jspb.BinaryReader} reader The BinaryReader to use.
  2086   * @return {!proto.keys.ImportRequest}
  2087   */
  2088  proto.keys.ImportRequest.deserializeBinaryFromReader = function(msg, reader) {
  2089    while (reader.nextField()) {
  2090      if (reader.isEndGroup()) {
  2091        break;
  2092      }
  2093      var field = reader.getFieldNumber();
  2094      switch (field) {
  2095      case 1:
  2096        var value = /** @type {string} */ (reader.readString());
  2097        msg.setPassphrase(value);
  2098        break;
  2099      case 2:
  2100        var value = /** @type {string} */ (reader.readString());
  2101        msg.setName(value);
  2102        break;
  2103      case 3:
  2104        var value = /** @type {string} */ (reader.readString());
  2105        msg.setCurvetype(value);
  2106        break;
  2107      case 4:
  2108        var value = /** @type {!Uint8Array} */ (reader.readBytes());
  2109        msg.setKeybytes(value);
  2110        break;
  2111      default:
  2112        reader.skipField();
  2113        break;
  2114      }
  2115    }
  2116    return msg;
  2117  };
  2118  
  2119  
  2120  /**
  2121   * Serializes the message to binary data (in protobuf wire format).
  2122   * @return {!Uint8Array}
  2123   */
  2124  proto.keys.ImportRequest.prototype.serializeBinary = function() {
  2125    var writer = new jspb.BinaryWriter();
  2126    proto.keys.ImportRequest.serializeBinaryToWriter(this, writer);
  2127    return writer.getResultBuffer();
  2128  };
  2129  
  2130  
  2131  /**
  2132   * Serializes the given message to binary data (in protobuf wire
  2133   * format), writing to the given BinaryWriter.
  2134   * @param {!proto.keys.ImportRequest} message
  2135   * @param {!jspb.BinaryWriter} writer
  2136   * @suppress {unusedLocalVariables} f is only used for nested messages
  2137   */
  2138  proto.keys.ImportRequest.serializeBinaryToWriter = function(message, writer) {
  2139    var f = undefined;
  2140    f = message.getPassphrase();
  2141    if (f.length > 0) {
  2142      writer.writeString(
  2143        1,
  2144        f
  2145      );
  2146    }
  2147    f = message.getName();
  2148    if (f.length > 0) {
  2149      writer.writeString(
  2150        2,
  2151        f
  2152      );
  2153    }
  2154    f = message.getCurvetype();
  2155    if (f.length > 0) {
  2156      writer.writeString(
  2157        3,
  2158        f
  2159      );
  2160    }
  2161    f = message.getKeybytes_asU8();
  2162    if (f.length > 0) {
  2163      writer.writeBytes(
  2164        4,
  2165        f
  2166      );
  2167    }
  2168  };
  2169  
  2170  
  2171  /**
  2172   * optional string Passphrase = 1;
  2173   * @return {string}
  2174   */
  2175  proto.keys.ImportRequest.prototype.getPassphrase = function() {
  2176    return /** @type {string} */ (jspb.Message.getFieldWithDefault(this, 1, ""));
  2177  };
  2178  
  2179  
  2180  /**
  2181   * @param {string} value
  2182   * @return {!proto.keys.ImportRequest} returns this
  2183   */
  2184  proto.keys.ImportRequest.prototype.setPassphrase = function(value) {
  2185    return jspb.Message.setProto3StringField(this, 1, value);
  2186  };
  2187  
  2188  
  2189  /**
  2190   * optional string Name = 2;
  2191   * @return {string}
  2192   */
  2193  proto.keys.ImportRequest.prototype.getName = function() {
  2194    return /** @type {string} */ (jspb.Message.getFieldWithDefault(this, 2, ""));
  2195  };
  2196  
  2197  
  2198  /**
  2199   * @param {string} value
  2200   * @return {!proto.keys.ImportRequest} returns this
  2201   */
  2202  proto.keys.ImportRequest.prototype.setName = function(value) {
  2203    return jspb.Message.setProto3StringField(this, 2, value);
  2204  };
  2205  
  2206  
  2207  /**
  2208   * optional string CurveType = 3;
  2209   * @return {string}
  2210   */
  2211  proto.keys.ImportRequest.prototype.getCurvetype = function() {
  2212    return /** @type {string} */ (jspb.Message.getFieldWithDefault(this, 3, ""));
  2213  };
  2214  
  2215  
  2216  /**
  2217   * @param {string} value
  2218   * @return {!proto.keys.ImportRequest} returns this
  2219   */
  2220  proto.keys.ImportRequest.prototype.setCurvetype = function(value) {
  2221    return jspb.Message.setProto3StringField(this, 3, value);
  2222  };
  2223  
  2224  
  2225  /**
  2226   * optional bytes KeyBytes = 4;
  2227   * @return {!(string|Uint8Array)}
  2228   */
  2229  proto.keys.ImportRequest.prototype.getKeybytes = function() {
  2230    return /** @type {!(string|Uint8Array)} */ (jspb.Message.getFieldWithDefault(this, 4, ""));
  2231  };
  2232  
  2233  
  2234  /**
  2235   * optional bytes KeyBytes = 4;
  2236   * This is a type-conversion wrapper around `getKeybytes()`
  2237   * @return {string}
  2238   */
  2239  proto.keys.ImportRequest.prototype.getKeybytes_asB64 = function() {
  2240    return /** @type {string} */ (jspb.Message.bytesAsB64(
  2241        this.getKeybytes()));
  2242  };
  2243  
  2244  
  2245  /**
  2246   * optional bytes KeyBytes = 4;
  2247   * Note that Uint8Array is not supported on all browsers.
  2248   * @see http://caniuse.com/Uint8Array
  2249   * This is a type-conversion wrapper around `getKeybytes()`
  2250   * @return {!Uint8Array}
  2251   */
  2252  proto.keys.ImportRequest.prototype.getKeybytes_asU8 = function() {
  2253    return /** @type {!Uint8Array} */ (jspb.Message.bytesAsU8(
  2254        this.getKeybytes()));
  2255  };
  2256  
  2257  
  2258  /**
  2259   * @param {!(string|Uint8Array)} value
  2260   * @return {!proto.keys.ImportRequest} returns this
  2261   */
  2262  proto.keys.ImportRequest.prototype.setKeybytes = function(value) {
  2263    return jspb.Message.setProto3BytesField(this, 4, value);
  2264  };
  2265  
  2266  
  2267  
  2268  
  2269  
  2270  if (jspb.Message.GENERATE_TO_OBJECT) {
  2271  /**
  2272   * Creates an object representation of this proto.
  2273   * Field names that are reserved in JavaScript and will be renamed to pb_name.
  2274   * Optional fields that are not set will be set to undefined.
  2275   * To access a reserved field use, foo.pb_<name>, eg, foo.pb_default.
  2276   * For the list of reserved names please see:
  2277   *     net/proto2/compiler/js/internal/generator.cc#kKeyword.
  2278   * @param {boolean=} opt_includeInstance Deprecated. whether to include the
  2279   *     JSPB instance for transitional soy proto support:
  2280   *     http://goto/soy-param-migration
  2281   * @return {!Object}
  2282   */
  2283  proto.keys.ExportRequest.prototype.toObject = function(opt_includeInstance) {
  2284    return proto.keys.ExportRequest.toObject(opt_includeInstance, this);
  2285  };
  2286  
  2287  
  2288  /**
  2289   * Static version of the {@see toObject} method.
  2290   * @param {boolean|undefined} includeInstance Deprecated. Whether to include
  2291   *     the JSPB instance for transitional soy proto support:
  2292   *     http://goto/soy-param-migration
  2293   * @param {!proto.keys.ExportRequest} msg The msg instance to transform.
  2294   * @return {!Object}
  2295   * @suppress {unusedLocalVariables} f is only used for nested messages
  2296   */
  2297  proto.keys.ExportRequest.toObject = function(includeInstance, msg) {
  2298    var f, obj = {
  2299      passphrase: jspb.Message.getFieldWithDefault(msg, 1, ""),
  2300      name: jspb.Message.getFieldWithDefault(msg, 2, ""),
  2301      address: jspb.Message.getFieldWithDefault(msg, 3, "")
  2302    };
  2303  
  2304    if (includeInstance) {
  2305      obj.$jspbMessageInstance = msg;
  2306    }
  2307    return obj;
  2308  };
  2309  }
  2310  
  2311  
  2312  /**
  2313   * Deserializes binary data (in protobuf wire format).
  2314   * @param {jspb.ByteSource} bytes The bytes to deserialize.
  2315   * @return {!proto.keys.ExportRequest}
  2316   */
  2317  proto.keys.ExportRequest.deserializeBinary = function(bytes) {
  2318    var reader = new jspb.BinaryReader(bytes);
  2319    var msg = new proto.keys.ExportRequest;
  2320    return proto.keys.ExportRequest.deserializeBinaryFromReader(msg, reader);
  2321  };
  2322  
  2323  
  2324  /**
  2325   * Deserializes binary data (in protobuf wire format) from the
  2326   * given reader into the given message object.
  2327   * @param {!proto.keys.ExportRequest} msg The message object to deserialize into.
  2328   * @param {!jspb.BinaryReader} reader The BinaryReader to use.
  2329   * @return {!proto.keys.ExportRequest}
  2330   */
  2331  proto.keys.ExportRequest.deserializeBinaryFromReader = function(msg, reader) {
  2332    while (reader.nextField()) {
  2333      if (reader.isEndGroup()) {
  2334        break;
  2335      }
  2336      var field = reader.getFieldNumber();
  2337      switch (field) {
  2338      case 1:
  2339        var value = /** @type {string} */ (reader.readString());
  2340        msg.setPassphrase(value);
  2341        break;
  2342      case 2:
  2343        var value = /** @type {string} */ (reader.readString());
  2344        msg.setName(value);
  2345        break;
  2346      case 3:
  2347        var value = /** @type {string} */ (reader.readString());
  2348        msg.setAddress(value);
  2349        break;
  2350      default:
  2351        reader.skipField();
  2352        break;
  2353      }
  2354    }
  2355    return msg;
  2356  };
  2357  
  2358  
  2359  /**
  2360   * Serializes the message to binary data (in protobuf wire format).
  2361   * @return {!Uint8Array}
  2362   */
  2363  proto.keys.ExportRequest.prototype.serializeBinary = function() {
  2364    var writer = new jspb.BinaryWriter();
  2365    proto.keys.ExportRequest.serializeBinaryToWriter(this, writer);
  2366    return writer.getResultBuffer();
  2367  };
  2368  
  2369  
  2370  /**
  2371   * Serializes the given message to binary data (in protobuf wire
  2372   * format), writing to the given BinaryWriter.
  2373   * @param {!proto.keys.ExportRequest} message
  2374   * @param {!jspb.BinaryWriter} writer
  2375   * @suppress {unusedLocalVariables} f is only used for nested messages
  2376   */
  2377  proto.keys.ExportRequest.serializeBinaryToWriter = function(message, writer) {
  2378    var f = undefined;
  2379    f = message.getPassphrase();
  2380    if (f.length > 0) {
  2381      writer.writeString(
  2382        1,
  2383        f
  2384      );
  2385    }
  2386    f = message.getName();
  2387    if (f.length > 0) {
  2388      writer.writeString(
  2389        2,
  2390        f
  2391      );
  2392    }
  2393    f = message.getAddress();
  2394    if (f.length > 0) {
  2395      writer.writeString(
  2396        3,
  2397        f
  2398      );
  2399    }
  2400  };
  2401  
  2402  
  2403  /**
  2404   * optional string Passphrase = 1;
  2405   * @return {string}
  2406   */
  2407  proto.keys.ExportRequest.prototype.getPassphrase = function() {
  2408    return /** @type {string} */ (jspb.Message.getFieldWithDefault(this, 1, ""));
  2409  };
  2410  
  2411  
  2412  /**
  2413   * @param {string} value
  2414   * @return {!proto.keys.ExportRequest} returns this
  2415   */
  2416  proto.keys.ExportRequest.prototype.setPassphrase = function(value) {
  2417    return jspb.Message.setProto3StringField(this, 1, value);
  2418  };
  2419  
  2420  
  2421  /**
  2422   * optional string Name = 2;
  2423   * @return {string}
  2424   */
  2425  proto.keys.ExportRequest.prototype.getName = function() {
  2426    return /** @type {string} */ (jspb.Message.getFieldWithDefault(this, 2, ""));
  2427  };
  2428  
  2429  
  2430  /**
  2431   * @param {string} value
  2432   * @return {!proto.keys.ExportRequest} returns this
  2433   */
  2434  proto.keys.ExportRequest.prototype.setName = function(value) {
  2435    return jspb.Message.setProto3StringField(this, 2, value);
  2436  };
  2437  
  2438  
  2439  /**
  2440   * optional string Address = 3;
  2441   * @return {string}
  2442   */
  2443  proto.keys.ExportRequest.prototype.getAddress = function() {
  2444    return /** @type {string} */ (jspb.Message.getFieldWithDefault(this, 3, ""));
  2445  };
  2446  
  2447  
  2448  /**
  2449   * @param {string} value
  2450   * @return {!proto.keys.ExportRequest} returns this
  2451   */
  2452  proto.keys.ExportRequest.prototype.setAddress = function(value) {
  2453    return jspb.Message.setProto3StringField(this, 3, value);
  2454  };
  2455  
  2456  
  2457  
  2458  
  2459  
  2460  if (jspb.Message.GENERATE_TO_OBJECT) {
  2461  /**
  2462   * Creates an object representation of this proto.
  2463   * Field names that are reserved in JavaScript and will be renamed to pb_name.
  2464   * Optional fields that are not set will be set to undefined.
  2465   * To access a reserved field use, foo.pb_<name>, eg, foo.pb_default.
  2466   * For the list of reserved names please see:
  2467   *     net/proto2/compiler/js/internal/generator.cc#kKeyword.
  2468   * @param {boolean=} opt_includeInstance Deprecated. whether to include the
  2469   *     JSPB instance for transitional soy proto support:
  2470   *     http://goto/soy-param-migration
  2471   * @return {!Object}
  2472   */
  2473  proto.keys.ExportResponse.prototype.toObject = function(opt_includeInstance) {
  2474    return proto.keys.ExportResponse.toObject(opt_includeInstance, this);
  2475  };
  2476  
  2477  
  2478  /**
  2479   * Static version of the {@see toObject} method.
  2480   * @param {boolean|undefined} includeInstance Deprecated. Whether to include
  2481   *     the JSPB instance for transitional soy proto support:
  2482   *     http://goto/soy-param-migration
  2483   * @param {!proto.keys.ExportResponse} msg The msg instance to transform.
  2484   * @return {!Object}
  2485   * @suppress {unusedLocalVariables} f is only used for nested messages
  2486   */
  2487  proto.keys.ExportResponse.toObject = function(includeInstance, msg) {
  2488    var f, obj = {
  2489      publickey: msg.getPublickey_asB64(),
  2490      privatekey: msg.getPrivatekey_asB64(),
  2491      address: msg.getAddress_asB64(),
  2492      curvetype: jspb.Message.getFieldWithDefault(msg, 4, "")
  2493    };
  2494  
  2495    if (includeInstance) {
  2496      obj.$jspbMessageInstance = msg;
  2497    }
  2498    return obj;
  2499  };
  2500  }
  2501  
  2502  
  2503  /**
  2504   * Deserializes binary data (in protobuf wire format).
  2505   * @param {jspb.ByteSource} bytes The bytes to deserialize.
  2506   * @return {!proto.keys.ExportResponse}
  2507   */
  2508  proto.keys.ExportResponse.deserializeBinary = function(bytes) {
  2509    var reader = new jspb.BinaryReader(bytes);
  2510    var msg = new proto.keys.ExportResponse;
  2511    return proto.keys.ExportResponse.deserializeBinaryFromReader(msg, reader);
  2512  };
  2513  
  2514  
  2515  /**
  2516   * Deserializes binary data (in protobuf wire format) from the
  2517   * given reader into the given message object.
  2518   * @param {!proto.keys.ExportResponse} msg The message object to deserialize into.
  2519   * @param {!jspb.BinaryReader} reader The BinaryReader to use.
  2520   * @return {!proto.keys.ExportResponse}
  2521   */
  2522  proto.keys.ExportResponse.deserializeBinaryFromReader = function(msg, reader) {
  2523    while (reader.nextField()) {
  2524      if (reader.isEndGroup()) {
  2525        break;
  2526      }
  2527      var field = reader.getFieldNumber();
  2528      switch (field) {
  2529      case 1:
  2530        var value = /** @type {!Uint8Array} */ (reader.readBytes());
  2531        msg.setPublickey(value);
  2532        break;
  2533      case 2:
  2534        var value = /** @type {!Uint8Array} */ (reader.readBytes());
  2535        msg.setPrivatekey(value);
  2536        break;
  2537      case 3:
  2538        var value = /** @type {!Uint8Array} */ (reader.readBytes());
  2539        msg.setAddress(value);
  2540        break;
  2541      case 4:
  2542        var value = /** @type {string} */ (reader.readString());
  2543        msg.setCurvetype(value);
  2544        break;
  2545      default:
  2546        reader.skipField();
  2547        break;
  2548      }
  2549    }
  2550    return msg;
  2551  };
  2552  
  2553  
  2554  /**
  2555   * Serializes the message to binary data (in protobuf wire format).
  2556   * @return {!Uint8Array}
  2557   */
  2558  proto.keys.ExportResponse.prototype.serializeBinary = function() {
  2559    var writer = new jspb.BinaryWriter();
  2560    proto.keys.ExportResponse.serializeBinaryToWriter(this, writer);
  2561    return writer.getResultBuffer();
  2562  };
  2563  
  2564  
  2565  /**
  2566   * Serializes the given message to binary data (in protobuf wire
  2567   * format), writing to the given BinaryWriter.
  2568   * @param {!proto.keys.ExportResponse} message
  2569   * @param {!jspb.BinaryWriter} writer
  2570   * @suppress {unusedLocalVariables} f is only used for nested messages
  2571   */
  2572  proto.keys.ExportResponse.serializeBinaryToWriter = function(message, writer) {
  2573    var f = undefined;
  2574    f = message.getPublickey_asU8();
  2575    if (f.length > 0) {
  2576      writer.writeBytes(
  2577        1,
  2578        f
  2579      );
  2580    }
  2581    f = message.getPrivatekey_asU8();
  2582    if (f.length > 0) {
  2583      writer.writeBytes(
  2584        2,
  2585        f
  2586      );
  2587    }
  2588    f = message.getAddress_asU8();
  2589    if (f.length > 0) {
  2590      writer.writeBytes(
  2591        3,
  2592        f
  2593      );
  2594    }
  2595    f = message.getCurvetype();
  2596    if (f.length > 0) {
  2597      writer.writeString(
  2598        4,
  2599        f
  2600      );
  2601    }
  2602  };
  2603  
  2604  
  2605  /**
  2606   * optional bytes Publickey = 1;
  2607   * @return {!(string|Uint8Array)}
  2608   */
  2609  proto.keys.ExportResponse.prototype.getPublickey = function() {
  2610    return /** @type {!(string|Uint8Array)} */ (jspb.Message.getFieldWithDefault(this, 1, ""));
  2611  };
  2612  
  2613  
  2614  /**
  2615   * optional bytes Publickey = 1;
  2616   * This is a type-conversion wrapper around `getPublickey()`
  2617   * @return {string}
  2618   */
  2619  proto.keys.ExportResponse.prototype.getPublickey_asB64 = function() {
  2620    return /** @type {string} */ (jspb.Message.bytesAsB64(
  2621        this.getPublickey()));
  2622  };
  2623  
  2624  
  2625  /**
  2626   * optional bytes Publickey = 1;
  2627   * Note that Uint8Array is not supported on all browsers.
  2628   * @see http://caniuse.com/Uint8Array
  2629   * This is a type-conversion wrapper around `getPublickey()`
  2630   * @return {!Uint8Array}
  2631   */
  2632  proto.keys.ExportResponse.prototype.getPublickey_asU8 = function() {
  2633    return /** @type {!Uint8Array} */ (jspb.Message.bytesAsU8(
  2634        this.getPublickey()));
  2635  };
  2636  
  2637  
  2638  /**
  2639   * @param {!(string|Uint8Array)} value
  2640   * @return {!proto.keys.ExportResponse} returns this
  2641   */
  2642  proto.keys.ExportResponse.prototype.setPublickey = function(value) {
  2643    return jspb.Message.setProto3BytesField(this, 1, value);
  2644  };
  2645  
  2646  
  2647  /**
  2648   * optional bytes Privatekey = 2;
  2649   * @return {!(string|Uint8Array)}
  2650   */
  2651  proto.keys.ExportResponse.prototype.getPrivatekey = function() {
  2652    return /** @type {!(string|Uint8Array)} */ (jspb.Message.getFieldWithDefault(this, 2, ""));
  2653  };
  2654  
  2655  
  2656  /**
  2657   * optional bytes Privatekey = 2;
  2658   * This is a type-conversion wrapper around `getPrivatekey()`
  2659   * @return {string}
  2660   */
  2661  proto.keys.ExportResponse.prototype.getPrivatekey_asB64 = function() {
  2662    return /** @type {string} */ (jspb.Message.bytesAsB64(
  2663        this.getPrivatekey()));
  2664  };
  2665  
  2666  
  2667  /**
  2668   * optional bytes Privatekey = 2;
  2669   * Note that Uint8Array is not supported on all browsers.
  2670   * @see http://caniuse.com/Uint8Array
  2671   * This is a type-conversion wrapper around `getPrivatekey()`
  2672   * @return {!Uint8Array}
  2673   */
  2674  proto.keys.ExportResponse.prototype.getPrivatekey_asU8 = function() {
  2675    return /** @type {!Uint8Array} */ (jspb.Message.bytesAsU8(
  2676        this.getPrivatekey()));
  2677  };
  2678  
  2679  
  2680  /**
  2681   * @param {!(string|Uint8Array)} value
  2682   * @return {!proto.keys.ExportResponse} returns this
  2683   */
  2684  proto.keys.ExportResponse.prototype.setPrivatekey = function(value) {
  2685    return jspb.Message.setProto3BytesField(this, 2, value);
  2686  };
  2687  
  2688  
  2689  /**
  2690   * optional bytes Address = 3;
  2691   * @return {!(string|Uint8Array)}
  2692   */
  2693  proto.keys.ExportResponse.prototype.getAddress = function() {
  2694    return /** @type {!(string|Uint8Array)} */ (jspb.Message.getFieldWithDefault(this, 3, ""));
  2695  };
  2696  
  2697  
  2698  /**
  2699   * optional bytes Address = 3;
  2700   * This is a type-conversion wrapper around `getAddress()`
  2701   * @return {string}
  2702   */
  2703  proto.keys.ExportResponse.prototype.getAddress_asB64 = function() {
  2704    return /** @type {string} */ (jspb.Message.bytesAsB64(
  2705        this.getAddress()));
  2706  };
  2707  
  2708  
  2709  /**
  2710   * optional bytes Address = 3;
  2711   * Note that Uint8Array is not supported on all browsers.
  2712   * @see http://caniuse.com/Uint8Array
  2713   * This is a type-conversion wrapper around `getAddress()`
  2714   * @return {!Uint8Array}
  2715   */
  2716  proto.keys.ExportResponse.prototype.getAddress_asU8 = function() {
  2717    return /** @type {!Uint8Array} */ (jspb.Message.bytesAsU8(
  2718        this.getAddress()));
  2719  };
  2720  
  2721  
  2722  /**
  2723   * @param {!(string|Uint8Array)} value
  2724   * @return {!proto.keys.ExportResponse} returns this
  2725   */
  2726  proto.keys.ExportResponse.prototype.setAddress = function(value) {
  2727    return jspb.Message.setProto3BytesField(this, 3, value);
  2728  };
  2729  
  2730  
  2731  /**
  2732   * optional string CurveType = 4;
  2733   * @return {string}
  2734   */
  2735  proto.keys.ExportResponse.prototype.getCurvetype = function() {
  2736    return /** @type {string} */ (jspb.Message.getFieldWithDefault(this, 4, ""));
  2737  };
  2738  
  2739  
  2740  /**
  2741   * @param {string} value
  2742   * @return {!proto.keys.ExportResponse} returns this
  2743   */
  2744  proto.keys.ExportResponse.prototype.setCurvetype = function(value) {
  2745    return jspb.Message.setProto3StringField(this, 4, value);
  2746  };
  2747  
  2748  
  2749  
  2750  
  2751  
  2752  if (jspb.Message.GENERATE_TO_OBJECT) {
  2753  /**
  2754   * Creates an object representation of this proto.
  2755   * Field names that are reserved in JavaScript and will be renamed to pb_name.
  2756   * Optional fields that are not set will be set to undefined.
  2757   * To access a reserved field use, foo.pb_<name>, eg, foo.pb_default.
  2758   * For the list of reserved names please see:
  2759   *     net/proto2/compiler/js/internal/generator.cc#kKeyword.
  2760   * @param {boolean=} opt_includeInstance Deprecated. whether to include the
  2761   *     JSPB instance for transitional soy proto support:
  2762   *     http://goto/soy-param-migration
  2763   * @return {!Object}
  2764   */
  2765  proto.keys.SignRequest.prototype.toObject = function(opt_includeInstance) {
  2766    return proto.keys.SignRequest.toObject(opt_includeInstance, this);
  2767  };
  2768  
  2769  
  2770  /**
  2771   * Static version of the {@see toObject} method.
  2772   * @param {boolean|undefined} includeInstance Deprecated. Whether to include
  2773   *     the JSPB instance for transitional soy proto support:
  2774   *     http://goto/soy-param-migration
  2775   * @param {!proto.keys.SignRequest} msg The msg instance to transform.
  2776   * @return {!Object}
  2777   * @suppress {unusedLocalVariables} f is only used for nested messages
  2778   */
  2779  proto.keys.SignRequest.toObject = function(includeInstance, msg) {
  2780    var f, obj = {
  2781      passphrase: jspb.Message.getFieldWithDefault(msg, 1, ""),
  2782      address: jspb.Message.getFieldWithDefault(msg, 2, ""),
  2783      name: jspb.Message.getFieldWithDefault(msg, 3, ""),
  2784      message: msg.getMessage_asB64()
  2785    };
  2786  
  2787    if (includeInstance) {
  2788      obj.$jspbMessageInstance = msg;
  2789    }
  2790    return obj;
  2791  };
  2792  }
  2793  
  2794  
  2795  /**
  2796   * Deserializes binary data (in protobuf wire format).
  2797   * @param {jspb.ByteSource} bytes The bytes to deserialize.
  2798   * @return {!proto.keys.SignRequest}
  2799   */
  2800  proto.keys.SignRequest.deserializeBinary = function(bytes) {
  2801    var reader = new jspb.BinaryReader(bytes);
  2802    var msg = new proto.keys.SignRequest;
  2803    return proto.keys.SignRequest.deserializeBinaryFromReader(msg, reader);
  2804  };
  2805  
  2806  
  2807  /**
  2808   * Deserializes binary data (in protobuf wire format) from the
  2809   * given reader into the given message object.
  2810   * @param {!proto.keys.SignRequest} msg The message object to deserialize into.
  2811   * @param {!jspb.BinaryReader} reader The BinaryReader to use.
  2812   * @return {!proto.keys.SignRequest}
  2813   */
  2814  proto.keys.SignRequest.deserializeBinaryFromReader = function(msg, reader) {
  2815    while (reader.nextField()) {
  2816      if (reader.isEndGroup()) {
  2817        break;
  2818      }
  2819      var field = reader.getFieldNumber();
  2820      switch (field) {
  2821      case 1:
  2822        var value = /** @type {string} */ (reader.readString());
  2823        msg.setPassphrase(value);
  2824        break;
  2825      case 2:
  2826        var value = /** @type {string} */ (reader.readString());
  2827        msg.setAddress(value);
  2828        break;
  2829      case 3:
  2830        var value = /** @type {string} */ (reader.readString());
  2831        msg.setName(value);
  2832        break;
  2833      case 4:
  2834        var value = /** @type {!Uint8Array} */ (reader.readBytes());
  2835        msg.setMessage(value);
  2836        break;
  2837      default:
  2838        reader.skipField();
  2839        break;
  2840      }
  2841    }
  2842    return msg;
  2843  };
  2844  
  2845  
  2846  /**
  2847   * Serializes the message to binary data (in protobuf wire format).
  2848   * @return {!Uint8Array}
  2849   */
  2850  proto.keys.SignRequest.prototype.serializeBinary = function() {
  2851    var writer = new jspb.BinaryWriter();
  2852    proto.keys.SignRequest.serializeBinaryToWriter(this, writer);
  2853    return writer.getResultBuffer();
  2854  };
  2855  
  2856  
  2857  /**
  2858   * Serializes the given message to binary data (in protobuf wire
  2859   * format), writing to the given BinaryWriter.
  2860   * @param {!proto.keys.SignRequest} message
  2861   * @param {!jspb.BinaryWriter} writer
  2862   * @suppress {unusedLocalVariables} f is only used for nested messages
  2863   */
  2864  proto.keys.SignRequest.serializeBinaryToWriter = function(message, writer) {
  2865    var f = undefined;
  2866    f = message.getPassphrase();
  2867    if (f.length > 0) {
  2868      writer.writeString(
  2869        1,
  2870        f
  2871      );
  2872    }
  2873    f = message.getAddress();
  2874    if (f.length > 0) {
  2875      writer.writeString(
  2876        2,
  2877        f
  2878      );
  2879    }
  2880    f = message.getName();
  2881    if (f.length > 0) {
  2882      writer.writeString(
  2883        3,
  2884        f
  2885      );
  2886    }
  2887    f = message.getMessage_asU8();
  2888    if (f.length > 0) {
  2889      writer.writeBytes(
  2890        4,
  2891        f
  2892      );
  2893    }
  2894  };
  2895  
  2896  
  2897  /**
  2898   * optional string Passphrase = 1;
  2899   * @return {string}
  2900   */
  2901  proto.keys.SignRequest.prototype.getPassphrase = function() {
  2902    return /** @type {string} */ (jspb.Message.getFieldWithDefault(this, 1, ""));
  2903  };
  2904  
  2905  
  2906  /**
  2907   * @param {string} value
  2908   * @return {!proto.keys.SignRequest} returns this
  2909   */
  2910  proto.keys.SignRequest.prototype.setPassphrase = function(value) {
  2911    return jspb.Message.setProto3StringField(this, 1, value);
  2912  };
  2913  
  2914  
  2915  /**
  2916   * optional string Address = 2;
  2917   * @return {string}
  2918   */
  2919  proto.keys.SignRequest.prototype.getAddress = function() {
  2920    return /** @type {string} */ (jspb.Message.getFieldWithDefault(this, 2, ""));
  2921  };
  2922  
  2923  
  2924  /**
  2925   * @param {string} value
  2926   * @return {!proto.keys.SignRequest} returns this
  2927   */
  2928  proto.keys.SignRequest.prototype.setAddress = function(value) {
  2929    return jspb.Message.setProto3StringField(this, 2, value);
  2930  };
  2931  
  2932  
  2933  /**
  2934   * optional string Name = 3;
  2935   * @return {string}
  2936   */
  2937  proto.keys.SignRequest.prototype.getName = function() {
  2938    return /** @type {string} */ (jspb.Message.getFieldWithDefault(this, 3, ""));
  2939  };
  2940  
  2941  
  2942  /**
  2943   * @param {string} value
  2944   * @return {!proto.keys.SignRequest} returns this
  2945   */
  2946  proto.keys.SignRequest.prototype.setName = function(value) {
  2947    return jspb.Message.setProto3StringField(this, 3, value);
  2948  };
  2949  
  2950  
  2951  /**
  2952   * optional bytes Message = 4;
  2953   * @return {!(string|Uint8Array)}
  2954   */
  2955  proto.keys.SignRequest.prototype.getMessage = function() {
  2956    return /** @type {!(string|Uint8Array)} */ (jspb.Message.getFieldWithDefault(this, 4, ""));
  2957  };
  2958  
  2959  
  2960  /**
  2961   * optional bytes Message = 4;
  2962   * This is a type-conversion wrapper around `getMessage()`
  2963   * @return {string}
  2964   */
  2965  proto.keys.SignRequest.prototype.getMessage_asB64 = function() {
  2966    return /** @type {string} */ (jspb.Message.bytesAsB64(
  2967        this.getMessage()));
  2968  };
  2969  
  2970  
  2971  /**
  2972   * optional bytes Message = 4;
  2973   * Note that Uint8Array is not supported on all browsers.
  2974   * @see http://caniuse.com/Uint8Array
  2975   * This is a type-conversion wrapper around `getMessage()`
  2976   * @return {!Uint8Array}
  2977   */
  2978  proto.keys.SignRequest.prototype.getMessage_asU8 = function() {
  2979    return /** @type {!Uint8Array} */ (jspb.Message.bytesAsU8(
  2980        this.getMessage()));
  2981  };
  2982  
  2983  
  2984  /**
  2985   * @param {!(string|Uint8Array)} value
  2986   * @return {!proto.keys.SignRequest} returns this
  2987   */
  2988  proto.keys.SignRequest.prototype.setMessage = function(value) {
  2989    return jspb.Message.setProto3BytesField(this, 4, value);
  2990  };
  2991  
  2992  
  2993  
  2994  
  2995  
  2996  if (jspb.Message.GENERATE_TO_OBJECT) {
  2997  /**
  2998   * Creates an object representation of this proto.
  2999   * Field names that are reserved in JavaScript and will be renamed to pb_name.
  3000   * Optional fields that are not set will be set to undefined.
  3001   * To access a reserved field use, foo.pb_<name>, eg, foo.pb_default.
  3002   * For the list of reserved names please see:
  3003   *     net/proto2/compiler/js/internal/generator.cc#kKeyword.
  3004   * @param {boolean=} opt_includeInstance Deprecated. whether to include the
  3005   *     JSPB instance for transitional soy proto support:
  3006   *     http://goto/soy-param-migration
  3007   * @return {!Object}
  3008   */
  3009  proto.keys.SignResponse.prototype.toObject = function(opt_includeInstance) {
  3010    return proto.keys.SignResponse.toObject(opt_includeInstance, this);
  3011  };
  3012  
  3013  
  3014  /**
  3015   * Static version of the {@see toObject} method.
  3016   * @param {boolean|undefined} includeInstance Deprecated. Whether to include
  3017   *     the JSPB instance for transitional soy proto support:
  3018   *     http://goto/soy-param-migration
  3019   * @param {!proto.keys.SignResponse} msg The msg instance to transform.
  3020   * @return {!Object}
  3021   * @suppress {unusedLocalVariables} f is only used for nested messages
  3022   */
  3023  proto.keys.SignResponse.toObject = function(includeInstance, msg) {
  3024    var f, obj = {
  3025      signature: (f = msg.getSignature()) && crypto_pb.Signature.toObject(includeInstance, f)
  3026    };
  3027  
  3028    if (includeInstance) {
  3029      obj.$jspbMessageInstance = msg;
  3030    }
  3031    return obj;
  3032  };
  3033  }
  3034  
  3035  
  3036  /**
  3037   * Deserializes binary data (in protobuf wire format).
  3038   * @param {jspb.ByteSource} bytes The bytes to deserialize.
  3039   * @return {!proto.keys.SignResponse}
  3040   */
  3041  proto.keys.SignResponse.deserializeBinary = function(bytes) {
  3042    var reader = new jspb.BinaryReader(bytes);
  3043    var msg = new proto.keys.SignResponse;
  3044    return proto.keys.SignResponse.deserializeBinaryFromReader(msg, reader);
  3045  };
  3046  
  3047  
  3048  /**
  3049   * Deserializes binary data (in protobuf wire format) from the
  3050   * given reader into the given message object.
  3051   * @param {!proto.keys.SignResponse} msg The message object to deserialize into.
  3052   * @param {!jspb.BinaryReader} reader The BinaryReader to use.
  3053   * @return {!proto.keys.SignResponse}
  3054   */
  3055  proto.keys.SignResponse.deserializeBinaryFromReader = function(msg, reader) {
  3056    while (reader.nextField()) {
  3057      if (reader.isEndGroup()) {
  3058        break;
  3059      }
  3060      var field = reader.getFieldNumber();
  3061      switch (field) {
  3062      case 3:
  3063        var value = new crypto_pb.Signature;
  3064        reader.readMessage(value,crypto_pb.Signature.deserializeBinaryFromReader);
  3065        msg.setSignature(value);
  3066        break;
  3067      default:
  3068        reader.skipField();
  3069        break;
  3070      }
  3071    }
  3072    return msg;
  3073  };
  3074  
  3075  
  3076  /**
  3077   * Serializes the message to binary data (in protobuf wire format).
  3078   * @return {!Uint8Array}
  3079   */
  3080  proto.keys.SignResponse.prototype.serializeBinary = function() {
  3081    var writer = new jspb.BinaryWriter();
  3082    proto.keys.SignResponse.serializeBinaryToWriter(this, writer);
  3083    return writer.getResultBuffer();
  3084  };
  3085  
  3086  
  3087  /**
  3088   * Serializes the given message to binary data (in protobuf wire
  3089   * format), writing to the given BinaryWriter.
  3090   * @param {!proto.keys.SignResponse} message
  3091   * @param {!jspb.BinaryWriter} writer
  3092   * @suppress {unusedLocalVariables} f is only used for nested messages
  3093   */
  3094  proto.keys.SignResponse.serializeBinaryToWriter = function(message, writer) {
  3095    var f = undefined;
  3096    f = message.getSignature();
  3097    if (f != null) {
  3098      writer.writeMessage(
  3099        3,
  3100        f,
  3101        crypto_pb.Signature.serializeBinaryToWriter
  3102      );
  3103    }
  3104  };
  3105  
  3106  
  3107  /**
  3108   * optional crypto.Signature Signature = 3;
  3109   * @return {?proto.crypto.Signature}
  3110   */
  3111  proto.keys.SignResponse.prototype.getSignature = function() {
  3112    return /** @type{?proto.crypto.Signature} */ (
  3113      jspb.Message.getWrapperField(this, crypto_pb.Signature, 3));
  3114  };
  3115  
  3116  
  3117  /**
  3118   * @param {?proto.crypto.Signature|undefined} value
  3119   * @return {!proto.keys.SignResponse} returns this
  3120  */
  3121  proto.keys.SignResponse.prototype.setSignature = function(value) {
  3122    return jspb.Message.setWrapperField(this, 3, value);
  3123  };
  3124  
  3125  
  3126  /**
  3127   * Clears the message field making it undefined.
  3128   * @return {!proto.keys.SignResponse} returns this
  3129   */
  3130  proto.keys.SignResponse.prototype.clearSignature = function() {
  3131    return this.setSignature(undefined);
  3132  };
  3133  
  3134  
  3135  /**
  3136   * Returns whether this field is set.
  3137   * @return {boolean}
  3138   */
  3139  proto.keys.SignResponse.prototype.hasSignature = function() {
  3140    return jspb.Message.getField(this, 3) != null;
  3141  };
  3142  
  3143  
  3144  
  3145  
  3146  
  3147  if (jspb.Message.GENERATE_TO_OBJECT) {
  3148  /**
  3149   * Creates an object representation of this proto.
  3150   * Field names that are reserved in JavaScript and will be renamed to pb_name.
  3151   * Optional fields that are not set will be set to undefined.
  3152   * To access a reserved field use, foo.pb_<name>, eg, foo.pb_default.
  3153   * For the list of reserved names please see:
  3154   *     net/proto2/compiler/js/internal/generator.cc#kKeyword.
  3155   * @param {boolean=} opt_includeInstance Deprecated. whether to include the
  3156   *     JSPB instance for transitional soy proto support:
  3157   *     http://goto/soy-param-migration
  3158   * @return {!Object}
  3159   */
  3160  proto.keys.VerifyRequest.prototype.toObject = function(opt_includeInstance) {
  3161    return proto.keys.VerifyRequest.toObject(opt_includeInstance, this);
  3162  };
  3163  
  3164  
  3165  /**
  3166   * Static version of the {@see toObject} method.
  3167   * @param {boolean|undefined} includeInstance Deprecated. Whether to include
  3168   *     the JSPB instance for transitional soy proto support:
  3169   *     http://goto/soy-param-migration
  3170   * @param {!proto.keys.VerifyRequest} msg The msg instance to transform.
  3171   * @return {!Object}
  3172   * @suppress {unusedLocalVariables} f is only used for nested messages
  3173   */
  3174  proto.keys.VerifyRequest.toObject = function(includeInstance, msg) {
  3175    var f, obj = {
  3176      publickey: msg.getPublickey_asB64(),
  3177      message: msg.getMessage_asB64(),
  3178      signature: (f = msg.getSignature()) && crypto_pb.Signature.toObject(includeInstance, f)
  3179    };
  3180  
  3181    if (includeInstance) {
  3182      obj.$jspbMessageInstance = msg;
  3183    }
  3184    return obj;
  3185  };
  3186  }
  3187  
  3188  
  3189  /**
  3190   * Deserializes binary data (in protobuf wire format).
  3191   * @param {jspb.ByteSource} bytes The bytes to deserialize.
  3192   * @return {!proto.keys.VerifyRequest}
  3193   */
  3194  proto.keys.VerifyRequest.deserializeBinary = function(bytes) {
  3195    var reader = new jspb.BinaryReader(bytes);
  3196    var msg = new proto.keys.VerifyRequest;
  3197    return proto.keys.VerifyRequest.deserializeBinaryFromReader(msg, reader);
  3198  };
  3199  
  3200  
  3201  /**
  3202   * Deserializes binary data (in protobuf wire format) from the
  3203   * given reader into the given message object.
  3204   * @param {!proto.keys.VerifyRequest} msg The message object to deserialize into.
  3205   * @param {!jspb.BinaryReader} reader The BinaryReader to use.
  3206   * @return {!proto.keys.VerifyRequest}
  3207   */
  3208  proto.keys.VerifyRequest.deserializeBinaryFromReader = function(msg, reader) {
  3209    while (reader.nextField()) {
  3210      if (reader.isEndGroup()) {
  3211        break;
  3212      }
  3213      var field = reader.getFieldNumber();
  3214      switch (field) {
  3215      case 2:
  3216        var value = /** @type {!Uint8Array} */ (reader.readBytes());
  3217        msg.setPublickey(value);
  3218        break;
  3219      case 3:
  3220        var value = /** @type {!Uint8Array} */ (reader.readBytes());
  3221        msg.setMessage(value);
  3222        break;
  3223      case 5:
  3224        var value = new crypto_pb.Signature;
  3225        reader.readMessage(value,crypto_pb.Signature.deserializeBinaryFromReader);
  3226        msg.setSignature(value);
  3227        break;
  3228      default:
  3229        reader.skipField();
  3230        break;
  3231      }
  3232    }
  3233    return msg;
  3234  };
  3235  
  3236  
  3237  /**
  3238   * Serializes the message to binary data (in protobuf wire format).
  3239   * @return {!Uint8Array}
  3240   */
  3241  proto.keys.VerifyRequest.prototype.serializeBinary = function() {
  3242    var writer = new jspb.BinaryWriter();
  3243    proto.keys.VerifyRequest.serializeBinaryToWriter(this, writer);
  3244    return writer.getResultBuffer();
  3245  };
  3246  
  3247  
  3248  /**
  3249   * Serializes the given message to binary data (in protobuf wire
  3250   * format), writing to the given BinaryWriter.
  3251   * @param {!proto.keys.VerifyRequest} message
  3252   * @param {!jspb.BinaryWriter} writer
  3253   * @suppress {unusedLocalVariables} f is only used for nested messages
  3254   */
  3255  proto.keys.VerifyRequest.serializeBinaryToWriter = function(message, writer) {
  3256    var f = undefined;
  3257    f = message.getPublickey_asU8();
  3258    if (f.length > 0) {
  3259      writer.writeBytes(
  3260        2,
  3261        f
  3262      );
  3263    }
  3264    f = message.getMessage_asU8();
  3265    if (f.length > 0) {
  3266      writer.writeBytes(
  3267        3,
  3268        f
  3269      );
  3270    }
  3271    f = message.getSignature();
  3272    if (f != null) {
  3273      writer.writeMessage(
  3274        5,
  3275        f,
  3276        crypto_pb.Signature.serializeBinaryToWriter
  3277      );
  3278    }
  3279  };
  3280  
  3281  
  3282  /**
  3283   * optional bytes PublicKey = 2;
  3284   * @return {!(string|Uint8Array)}
  3285   */
  3286  proto.keys.VerifyRequest.prototype.getPublickey = function() {
  3287    return /** @type {!(string|Uint8Array)} */ (jspb.Message.getFieldWithDefault(this, 2, ""));
  3288  };
  3289  
  3290  
  3291  /**
  3292   * optional bytes PublicKey = 2;
  3293   * This is a type-conversion wrapper around `getPublickey()`
  3294   * @return {string}
  3295   */
  3296  proto.keys.VerifyRequest.prototype.getPublickey_asB64 = function() {
  3297    return /** @type {string} */ (jspb.Message.bytesAsB64(
  3298        this.getPublickey()));
  3299  };
  3300  
  3301  
  3302  /**
  3303   * optional bytes PublicKey = 2;
  3304   * Note that Uint8Array is not supported on all browsers.
  3305   * @see http://caniuse.com/Uint8Array
  3306   * This is a type-conversion wrapper around `getPublickey()`
  3307   * @return {!Uint8Array}
  3308   */
  3309  proto.keys.VerifyRequest.prototype.getPublickey_asU8 = function() {
  3310    return /** @type {!Uint8Array} */ (jspb.Message.bytesAsU8(
  3311        this.getPublickey()));
  3312  };
  3313  
  3314  
  3315  /**
  3316   * @param {!(string|Uint8Array)} value
  3317   * @return {!proto.keys.VerifyRequest} returns this
  3318   */
  3319  proto.keys.VerifyRequest.prototype.setPublickey = function(value) {
  3320    return jspb.Message.setProto3BytesField(this, 2, value);
  3321  };
  3322  
  3323  
  3324  /**
  3325   * optional bytes Message = 3;
  3326   * @return {!(string|Uint8Array)}
  3327   */
  3328  proto.keys.VerifyRequest.prototype.getMessage = function() {
  3329    return /** @type {!(string|Uint8Array)} */ (jspb.Message.getFieldWithDefault(this, 3, ""));
  3330  };
  3331  
  3332  
  3333  /**
  3334   * optional bytes Message = 3;
  3335   * This is a type-conversion wrapper around `getMessage()`
  3336   * @return {string}
  3337   */
  3338  proto.keys.VerifyRequest.prototype.getMessage_asB64 = function() {
  3339    return /** @type {string} */ (jspb.Message.bytesAsB64(
  3340        this.getMessage()));
  3341  };
  3342  
  3343  
  3344  /**
  3345   * optional bytes Message = 3;
  3346   * Note that Uint8Array is not supported on all browsers.
  3347   * @see http://caniuse.com/Uint8Array
  3348   * This is a type-conversion wrapper around `getMessage()`
  3349   * @return {!Uint8Array}
  3350   */
  3351  proto.keys.VerifyRequest.prototype.getMessage_asU8 = function() {
  3352    return /** @type {!Uint8Array} */ (jspb.Message.bytesAsU8(
  3353        this.getMessage()));
  3354  };
  3355  
  3356  
  3357  /**
  3358   * @param {!(string|Uint8Array)} value
  3359   * @return {!proto.keys.VerifyRequest} returns this
  3360   */
  3361  proto.keys.VerifyRequest.prototype.setMessage = function(value) {
  3362    return jspb.Message.setProto3BytesField(this, 3, value);
  3363  };
  3364  
  3365  
  3366  /**
  3367   * optional crypto.Signature Signature = 5;
  3368   * @return {?proto.crypto.Signature}
  3369   */
  3370  proto.keys.VerifyRequest.prototype.getSignature = function() {
  3371    return /** @type{?proto.crypto.Signature} */ (
  3372      jspb.Message.getWrapperField(this, crypto_pb.Signature, 5));
  3373  };
  3374  
  3375  
  3376  /**
  3377   * @param {?proto.crypto.Signature|undefined} value
  3378   * @return {!proto.keys.VerifyRequest} returns this
  3379  */
  3380  proto.keys.VerifyRequest.prototype.setSignature = function(value) {
  3381    return jspb.Message.setWrapperField(this, 5, value);
  3382  };
  3383  
  3384  
  3385  /**
  3386   * Clears the message field making it undefined.
  3387   * @return {!proto.keys.VerifyRequest} returns this
  3388   */
  3389  proto.keys.VerifyRequest.prototype.clearSignature = function() {
  3390    return this.setSignature(undefined);
  3391  };
  3392  
  3393  
  3394  /**
  3395   * Returns whether this field is set.
  3396   * @return {boolean}
  3397   */
  3398  proto.keys.VerifyRequest.prototype.hasSignature = function() {
  3399    return jspb.Message.getField(this, 5) != null;
  3400  };
  3401  
  3402  
  3403  
  3404  
  3405  
  3406  if (jspb.Message.GENERATE_TO_OBJECT) {
  3407  /**
  3408   * Creates an object representation of this proto.
  3409   * Field names that are reserved in JavaScript and will be renamed to pb_name.
  3410   * Optional fields that are not set will be set to undefined.
  3411   * To access a reserved field use, foo.pb_<name>, eg, foo.pb_default.
  3412   * For the list of reserved names please see:
  3413   *     net/proto2/compiler/js/internal/generator.cc#kKeyword.
  3414   * @param {boolean=} opt_includeInstance Deprecated. whether to include the
  3415   *     JSPB instance for transitional soy proto support:
  3416   *     http://goto/soy-param-migration
  3417   * @return {!Object}
  3418   */
  3419  proto.keys.HashRequest.prototype.toObject = function(opt_includeInstance) {
  3420    return proto.keys.HashRequest.toObject(opt_includeInstance, this);
  3421  };
  3422  
  3423  
  3424  /**
  3425   * Static version of the {@see toObject} method.
  3426   * @param {boolean|undefined} includeInstance Deprecated. Whether to include
  3427   *     the JSPB instance for transitional soy proto support:
  3428   *     http://goto/soy-param-migration
  3429   * @param {!proto.keys.HashRequest} msg The msg instance to transform.
  3430   * @return {!Object}
  3431   * @suppress {unusedLocalVariables} f is only used for nested messages
  3432   */
  3433  proto.keys.HashRequest.toObject = function(includeInstance, msg) {
  3434    var f, obj = {
  3435      hashtype: jspb.Message.getFieldWithDefault(msg, 1, ""),
  3436      message: msg.getMessage_asB64()
  3437    };
  3438  
  3439    if (includeInstance) {
  3440      obj.$jspbMessageInstance = msg;
  3441    }
  3442    return obj;
  3443  };
  3444  }
  3445  
  3446  
  3447  /**
  3448   * Deserializes binary data (in protobuf wire format).
  3449   * @param {jspb.ByteSource} bytes The bytes to deserialize.
  3450   * @return {!proto.keys.HashRequest}
  3451   */
  3452  proto.keys.HashRequest.deserializeBinary = function(bytes) {
  3453    var reader = new jspb.BinaryReader(bytes);
  3454    var msg = new proto.keys.HashRequest;
  3455    return proto.keys.HashRequest.deserializeBinaryFromReader(msg, reader);
  3456  };
  3457  
  3458  
  3459  /**
  3460   * Deserializes binary data (in protobuf wire format) from the
  3461   * given reader into the given message object.
  3462   * @param {!proto.keys.HashRequest} msg The message object to deserialize into.
  3463   * @param {!jspb.BinaryReader} reader The BinaryReader to use.
  3464   * @return {!proto.keys.HashRequest}
  3465   */
  3466  proto.keys.HashRequest.deserializeBinaryFromReader = function(msg, reader) {
  3467    while (reader.nextField()) {
  3468      if (reader.isEndGroup()) {
  3469        break;
  3470      }
  3471      var field = reader.getFieldNumber();
  3472      switch (field) {
  3473      case 1:
  3474        var value = /** @type {string} */ (reader.readString());
  3475        msg.setHashtype(value);
  3476        break;
  3477      case 2:
  3478        var value = /** @type {!Uint8Array} */ (reader.readBytes());
  3479        msg.setMessage(value);
  3480        break;
  3481      default:
  3482        reader.skipField();
  3483        break;
  3484      }
  3485    }
  3486    return msg;
  3487  };
  3488  
  3489  
  3490  /**
  3491   * Serializes the message to binary data (in protobuf wire format).
  3492   * @return {!Uint8Array}
  3493   */
  3494  proto.keys.HashRequest.prototype.serializeBinary = function() {
  3495    var writer = new jspb.BinaryWriter();
  3496    proto.keys.HashRequest.serializeBinaryToWriter(this, writer);
  3497    return writer.getResultBuffer();
  3498  };
  3499  
  3500  
  3501  /**
  3502   * Serializes the given message to binary data (in protobuf wire
  3503   * format), writing to the given BinaryWriter.
  3504   * @param {!proto.keys.HashRequest} message
  3505   * @param {!jspb.BinaryWriter} writer
  3506   * @suppress {unusedLocalVariables} f is only used for nested messages
  3507   */
  3508  proto.keys.HashRequest.serializeBinaryToWriter = function(message, writer) {
  3509    var f = undefined;
  3510    f = message.getHashtype();
  3511    if (f.length > 0) {
  3512      writer.writeString(
  3513        1,
  3514        f
  3515      );
  3516    }
  3517    f = message.getMessage_asU8();
  3518    if (f.length > 0) {
  3519      writer.writeBytes(
  3520        2,
  3521        f
  3522      );
  3523    }
  3524  };
  3525  
  3526  
  3527  /**
  3528   * optional string Hashtype = 1;
  3529   * @return {string}
  3530   */
  3531  proto.keys.HashRequest.prototype.getHashtype = function() {
  3532    return /** @type {string} */ (jspb.Message.getFieldWithDefault(this, 1, ""));
  3533  };
  3534  
  3535  
  3536  /**
  3537   * @param {string} value
  3538   * @return {!proto.keys.HashRequest} returns this
  3539   */
  3540  proto.keys.HashRequest.prototype.setHashtype = function(value) {
  3541    return jspb.Message.setProto3StringField(this, 1, value);
  3542  };
  3543  
  3544  
  3545  /**
  3546   * optional bytes Message = 2;
  3547   * @return {!(string|Uint8Array)}
  3548   */
  3549  proto.keys.HashRequest.prototype.getMessage = function() {
  3550    return /** @type {!(string|Uint8Array)} */ (jspb.Message.getFieldWithDefault(this, 2, ""));
  3551  };
  3552  
  3553  
  3554  /**
  3555   * optional bytes Message = 2;
  3556   * This is a type-conversion wrapper around `getMessage()`
  3557   * @return {string}
  3558   */
  3559  proto.keys.HashRequest.prototype.getMessage_asB64 = function() {
  3560    return /** @type {string} */ (jspb.Message.bytesAsB64(
  3561        this.getMessage()));
  3562  };
  3563  
  3564  
  3565  /**
  3566   * optional bytes Message = 2;
  3567   * Note that Uint8Array is not supported on all browsers.
  3568   * @see http://caniuse.com/Uint8Array
  3569   * This is a type-conversion wrapper around `getMessage()`
  3570   * @return {!Uint8Array}
  3571   */
  3572  proto.keys.HashRequest.prototype.getMessage_asU8 = function() {
  3573    return /** @type {!Uint8Array} */ (jspb.Message.bytesAsU8(
  3574        this.getMessage()));
  3575  };
  3576  
  3577  
  3578  /**
  3579   * @param {!(string|Uint8Array)} value
  3580   * @return {!proto.keys.HashRequest} returns this
  3581   */
  3582  proto.keys.HashRequest.prototype.setMessage = function(value) {
  3583    return jspb.Message.setProto3BytesField(this, 2, value);
  3584  };
  3585  
  3586  
  3587  
  3588  
  3589  
  3590  if (jspb.Message.GENERATE_TO_OBJECT) {
  3591  /**
  3592   * Creates an object representation of this proto.
  3593   * Field names that are reserved in JavaScript and will be renamed to pb_name.
  3594   * Optional fields that are not set will be set to undefined.
  3595   * To access a reserved field use, foo.pb_<name>, eg, foo.pb_default.
  3596   * For the list of reserved names please see:
  3597   *     net/proto2/compiler/js/internal/generator.cc#kKeyword.
  3598   * @param {boolean=} opt_includeInstance Deprecated. whether to include the
  3599   *     JSPB instance for transitional soy proto support:
  3600   *     http://goto/soy-param-migration
  3601   * @return {!Object}
  3602   */
  3603  proto.keys.HashResponse.prototype.toObject = function(opt_includeInstance) {
  3604    return proto.keys.HashResponse.toObject(opt_includeInstance, this);
  3605  };
  3606  
  3607  
  3608  /**
  3609   * Static version of the {@see toObject} method.
  3610   * @param {boolean|undefined} includeInstance Deprecated. Whether to include
  3611   *     the JSPB instance for transitional soy proto support:
  3612   *     http://goto/soy-param-migration
  3613   * @param {!proto.keys.HashResponse} msg The msg instance to transform.
  3614   * @return {!Object}
  3615   * @suppress {unusedLocalVariables} f is only used for nested messages
  3616   */
  3617  proto.keys.HashResponse.toObject = function(includeInstance, msg) {
  3618    var f, obj = {
  3619      hash: jspb.Message.getFieldWithDefault(msg, 1, "")
  3620    };
  3621  
  3622    if (includeInstance) {
  3623      obj.$jspbMessageInstance = msg;
  3624    }
  3625    return obj;
  3626  };
  3627  }
  3628  
  3629  
  3630  /**
  3631   * Deserializes binary data (in protobuf wire format).
  3632   * @param {jspb.ByteSource} bytes The bytes to deserialize.
  3633   * @return {!proto.keys.HashResponse}
  3634   */
  3635  proto.keys.HashResponse.deserializeBinary = function(bytes) {
  3636    var reader = new jspb.BinaryReader(bytes);
  3637    var msg = new proto.keys.HashResponse;
  3638    return proto.keys.HashResponse.deserializeBinaryFromReader(msg, reader);
  3639  };
  3640  
  3641  
  3642  /**
  3643   * Deserializes binary data (in protobuf wire format) from the
  3644   * given reader into the given message object.
  3645   * @param {!proto.keys.HashResponse} msg The message object to deserialize into.
  3646   * @param {!jspb.BinaryReader} reader The BinaryReader to use.
  3647   * @return {!proto.keys.HashResponse}
  3648   */
  3649  proto.keys.HashResponse.deserializeBinaryFromReader = function(msg, reader) {
  3650    while (reader.nextField()) {
  3651      if (reader.isEndGroup()) {
  3652        break;
  3653      }
  3654      var field = reader.getFieldNumber();
  3655      switch (field) {
  3656      case 1:
  3657        var value = /** @type {string} */ (reader.readString());
  3658        msg.setHash(value);
  3659        break;
  3660      default:
  3661        reader.skipField();
  3662        break;
  3663      }
  3664    }
  3665    return msg;
  3666  };
  3667  
  3668  
  3669  /**
  3670   * Serializes the message to binary data (in protobuf wire format).
  3671   * @return {!Uint8Array}
  3672   */
  3673  proto.keys.HashResponse.prototype.serializeBinary = function() {
  3674    var writer = new jspb.BinaryWriter();
  3675    proto.keys.HashResponse.serializeBinaryToWriter(this, writer);
  3676    return writer.getResultBuffer();
  3677  };
  3678  
  3679  
  3680  /**
  3681   * Serializes the given message to binary data (in protobuf wire
  3682   * format), writing to the given BinaryWriter.
  3683   * @param {!proto.keys.HashResponse} message
  3684   * @param {!jspb.BinaryWriter} writer
  3685   * @suppress {unusedLocalVariables} f is only used for nested messages
  3686   */
  3687  proto.keys.HashResponse.serializeBinaryToWriter = function(message, writer) {
  3688    var f = undefined;
  3689    f = message.getHash();
  3690    if (f.length > 0) {
  3691      writer.writeString(
  3692        1,
  3693        f
  3694      );
  3695    }
  3696  };
  3697  
  3698  
  3699  /**
  3700   * optional string Hash = 1;
  3701   * @return {string}
  3702   */
  3703  proto.keys.HashResponse.prototype.getHash = function() {
  3704    return /** @type {string} */ (jspb.Message.getFieldWithDefault(this, 1, ""));
  3705  };
  3706  
  3707  
  3708  /**
  3709   * @param {string} value
  3710   * @return {!proto.keys.HashResponse} returns this
  3711   */
  3712  proto.keys.HashResponse.prototype.setHash = function(value) {
  3713    return jspb.Message.setProto3StringField(this, 1, value);
  3714  };
  3715  
  3716  
  3717  
  3718  /**
  3719   * List of repeated fields within this message type.
  3720   * @private {!Array<number>}
  3721   * @const
  3722   */
  3723  proto.keys.KeyID.repeatedFields_ = [2];
  3724  
  3725  
  3726  
  3727  if (jspb.Message.GENERATE_TO_OBJECT) {
  3728  /**
  3729   * Creates an object representation of this proto.
  3730   * Field names that are reserved in JavaScript and will be renamed to pb_name.
  3731   * Optional fields that are not set will be set to undefined.
  3732   * To access a reserved field use, foo.pb_<name>, eg, foo.pb_default.
  3733   * For the list of reserved names please see:
  3734   *     net/proto2/compiler/js/internal/generator.cc#kKeyword.
  3735   * @param {boolean=} opt_includeInstance Deprecated. whether to include the
  3736   *     JSPB instance for transitional soy proto support:
  3737   *     http://goto/soy-param-migration
  3738   * @return {!Object}
  3739   */
  3740  proto.keys.KeyID.prototype.toObject = function(opt_includeInstance) {
  3741    return proto.keys.KeyID.toObject(opt_includeInstance, this);
  3742  };
  3743  
  3744  
  3745  /**
  3746   * Static version of the {@see toObject} method.
  3747   * @param {boolean|undefined} includeInstance Deprecated. Whether to include
  3748   *     the JSPB instance for transitional soy proto support:
  3749   *     http://goto/soy-param-migration
  3750   * @param {!proto.keys.KeyID} msg The msg instance to transform.
  3751   * @return {!Object}
  3752   * @suppress {unusedLocalVariables} f is only used for nested messages
  3753   */
  3754  proto.keys.KeyID.toObject = function(includeInstance, msg) {
  3755    var f, obj = {
  3756      address: jspb.Message.getFieldWithDefault(msg, 1, ""),
  3757      keynameList: (f = jspb.Message.getRepeatedField(msg, 2)) == null ? undefined : f
  3758    };
  3759  
  3760    if (includeInstance) {
  3761      obj.$jspbMessageInstance = msg;
  3762    }
  3763    return obj;
  3764  };
  3765  }
  3766  
  3767  
  3768  /**
  3769   * Deserializes binary data (in protobuf wire format).
  3770   * @param {jspb.ByteSource} bytes The bytes to deserialize.
  3771   * @return {!proto.keys.KeyID}
  3772   */
  3773  proto.keys.KeyID.deserializeBinary = function(bytes) {
  3774    var reader = new jspb.BinaryReader(bytes);
  3775    var msg = new proto.keys.KeyID;
  3776    return proto.keys.KeyID.deserializeBinaryFromReader(msg, reader);
  3777  };
  3778  
  3779  
  3780  /**
  3781   * Deserializes binary data (in protobuf wire format) from the
  3782   * given reader into the given message object.
  3783   * @param {!proto.keys.KeyID} msg The message object to deserialize into.
  3784   * @param {!jspb.BinaryReader} reader The BinaryReader to use.
  3785   * @return {!proto.keys.KeyID}
  3786   */
  3787  proto.keys.KeyID.deserializeBinaryFromReader = function(msg, reader) {
  3788    while (reader.nextField()) {
  3789      if (reader.isEndGroup()) {
  3790        break;
  3791      }
  3792      var field = reader.getFieldNumber();
  3793      switch (field) {
  3794      case 1:
  3795        var value = /** @type {string} */ (reader.readString());
  3796        msg.setAddress(value);
  3797        break;
  3798      case 2:
  3799        var value = /** @type {string} */ (reader.readString());
  3800        msg.addKeyname(value);
  3801        break;
  3802      default:
  3803        reader.skipField();
  3804        break;
  3805      }
  3806    }
  3807    return msg;
  3808  };
  3809  
  3810  
  3811  /**
  3812   * Serializes the message to binary data (in protobuf wire format).
  3813   * @return {!Uint8Array}
  3814   */
  3815  proto.keys.KeyID.prototype.serializeBinary = function() {
  3816    var writer = new jspb.BinaryWriter();
  3817    proto.keys.KeyID.serializeBinaryToWriter(this, writer);
  3818    return writer.getResultBuffer();
  3819  };
  3820  
  3821  
  3822  /**
  3823   * Serializes the given message to binary data (in protobuf wire
  3824   * format), writing to the given BinaryWriter.
  3825   * @param {!proto.keys.KeyID} message
  3826   * @param {!jspb.BinaryWriter} writer
  3827   * @suppress {unusedLocalVariables} f is only used for nested messages
  3828   */
  3829  proto.keys.KeyID.serializeBinaryToWriter = function(message, writer) {
  3830    var f = undefined;
  3831    f = message.getAddress();
  3832    if (f.length > 0) {
  3833      writer.writeString(
  3834        1,
  3835        f
  3836      );
  3837    }
  3838    f = message.getKeynameList();
  3839    if (f.length > 0) {
  3840      writer.writeRepeatedString(
  3841        2,
  3842        f
  3843      );
  3844    }
  3845  };
  3846  
  3847  
  3848  /**
  3849   * optional string Address = 1;
  3850   * @return {string}
  3851   */
  3852  proto.keys.KeyID.prototype.getAddress = function() {
  3853    return /** @type {string} */ (jspb.Message.getFieldWithDefault(this, 1, ""));
  3854  };
  3855  
  3856  
  3857  /**
  3858   * @param {string} value
  3859   * @return {!proto.keys.KeyID} returns this
  3860   */
  3861  proto.keys.KeyID.prototype.setAddress = function(value) {
  3862    return jspb.Message.setProto3StringField(this, 1, value);
  3863  };
  3864  
  3865  
  3866  /**
  3867   * repeated string KeyName = 2;
  3868   * @return {!Array<string>}
  3869   */
  3870  proto.keys.KeyID.prototype.getKeynameList = function() {
  3871    return /** @type {!Array<string>} */ (jspb.Message.getRepeatedField(this, 2));
  3872  };
  3873  
  3874  
  3875  /**
  3876   * @param {!Array<string>} value
  3877   * @return {!proto.keys.KeyID} returns this
  3878   */
  3879  proto.keys.KeyID.prototype.setKeynameList = function(value) {
  3880    return jspb.Message.setField(this, 2, value || []);
  3881  };
  3882  
  3883  
  3884  /**
  3885   * @param {string} value
  3886   * @param {number=} opt_index
  3887   * @return {!proto.keys.KeyID} returns this
  3888   */
  3889  proto.keys.KeyID.prototype.addKeyname = function(value, opt_index) {
  3890    return jspb.Message.addToRepeatedField(this, 2, value, opt_index);
  3891  };
  3892  
  3893  
  3894  /**
  3895   * Clears the list making it empty but non-null.
  3896   * @return {!proto.keys.KeyID} returns this
  3897   */
  3898  proto.keys.KeyID.prototype.clearKeynameList = function() {
  3899    return this.setKeynameList([]);
  3900  };
  3901  
  3902  
  3903  
  3904  /**
  3905   * List of repeated fields within this message type.
  3906   * @private {!Array<number>}
  3907   * @const
  3908   */
  3909  proto.keys.ListResponse.repeatedFields_ = [1];
  3910  
  3911  
  3912  
  3913  if (jspb.Message.GENERATE_TO_OBJECT) {
  3914  /**
  3915   * Creates an object representation of this proto.
  3916   * Field names that are reserved in JavaScript and will be renamed to pb_name.
  3917   * Optional fields that are not set will be set to undefined.
  3918   * To access a reserved field use, foo.pb_<name>, eg, foo.pb_default.
  3919   * For the list of reserved names please see:
  3920   *     net/proto2/compiler/js/internal/generator.cc#kKeyword.
  3921   * @param {boolean=} opt_includeInstance Deprecated. whether to include the
  3922   *     JSPB instance for transitional soy proto support:
  3923   *     http://goto/soy-param-migration
  3924   * @return {!Object}
  3925   */
  3926  proto.keys.ListResponse.prototype.toObject = function(opt_includeInstance) {
  3927    return proto.keys.ListResponse.toObject(opt_includeInstance, this);
  3928  };
  3929  
  3930  
  3931  /**
  3932   * Static version of the {@see toObject} method.
  3933   * @param {boolean|undefined} includeInstance Deprecated. Whether to include
  3934   *     the JSPB instance for transitional soy proto support:
  3935   *     http://goto/soy-param-migration
  3936   * @param {!proto.keys.ListResponse} msg The msg instance to transform.
  3937   * @return {!Object}
  3938   * @suppress {unusedLocalVariables} f is only used for nested messages
  3939   */
  3940  proto.keys.ListResponse.toObject = function(includeInstance, msg) {
  3941    var f, obj = {
  3942      keyList: jspb.Message.toObjectList(msg.getKeyList(),
  3943      proto.keys.KeyID.toObject, includeInstance)
  3944    };
  3945  
  3946    if (includeInstance) {
  3947      obj.$jspbMessageInstance = msg;
  3948    }
  3949    return obj;
  3950  };
  3951  }
  3952  
  3953  
  3954  /**
  3955   * Deserializes binary data (in protobuf wire format).
  3956   * @param {jspb.ByteSource} bytes The bytes to deserialize.
  3957   * @return {!proto.keys.ListResponse}
  3958   */
  3959  proto.keys.ListResponse.deserializeBinary = function(bytes) {
  3960    var reader = new jspb.BinaryReader(bytes);
  3961    var msg = new proto.keys.ListResponse;
  3962    return proto.keys.ListResponse.deserializeBinaryFromReader(msg, reader);
  3963  };
  3964  
  3965  
  3966  /**
  3967   * Deserializes binary data (in protobuf wire format) from the
  3968   * given reader into the given message object.
  3969   * @param {!proto.keys.ListResponse} msg The message object to deserialize into.
  3970   * @param {!jspb.BinaryReader} reader The BinaryReader to use.
  3971   * @return {!proto.keys.ListResponse}
  3972   */
  3973  proto.keys.ListResponse.deserializeBinaryFromReader = function(msg, reader) {
  3974    while (reader.nextField()) {
  3975      if (reader.isEndGroup()) {
  3976        break;
  3977      }
  3978      var field = reader.getFieldNumber();
  3979      switch (field) {
  3980      case 1:
  3981        var value = new proto.keys.KeyID;
  3982        reader.readMessage(value,proto.keys.KeyID.deserializeBinaryFromReader);
  3983        msg.addKey(value);
  3984        break;
  3985      default:
  3986        reader.skipField();
  3987        break;
  3988      }
  3989    }
  3990    return msg;
  3991  };
  3992  
  3993  
  3994  /**
  3995   * Serializes the message to binary data (in protobuf wire format).
  3996   * @return {!Uint8Array}
  3997   */
  3998  proto.keys.ListResponse.prototype.serializeBinary = function() {
  3999    var writer = new jspb.BinaryWriter();
  4000    proto.keys.ListResponse.serializeBinaryToWriter(this, writer);
  4001    return writer.getResultBuffer();
  4002  };
  4003  
  4004  
  4005  /**
  4006   * Serializes the given message to binary data (in protobuf wire
  4007   * format), writing to the given BinaryWriter.
  4008   * @param {!proto.keys.ListResponse} message
  4009   * @param {!jspb.BinaryWriter} writer
  4010   * @suppress {unusedLocalVariables} f is only used for nested messages
  4011   */
  4012  proto.keys.ListResponse.serializeBinaryToWriter = function(message, writer) {
  4013    var f = undefined;
  4014    f = message.getKeyList();
  4015    if (f.length > 0) {
  4016      writer.writeRepeatedMessage(
  4017        1,
  4018        f,
  4019        proto.keys.KeyID.serializeBinaryToWriter
  4020      );
  4021    }
  4022  };
  4023  
  4024  
  4025  /**
  4026   * repeated KeyID key = 1;
  4027   * @return {!Array<!proto.keys.KeyID>}
  4028   */
  4029  proto.keys.ListResponse.prototype.getKeyList = function() {
  4030    return /** @type{!Array<!proto.keys.KeyID>} */ (
  4031      jspb.Message.getRepeatedWrapperField(this, proto.keys.KeyID, 1));
  4032  };
  4033  
  4034  
  4035  /**
  4036   * @param {!Array<!proto.keys.KeyID>} value
  4037   * @return {!proto.keys.ListResponse} returns this
  4038  */
  4039  proto.keys.ListResponse.prototype.setKeyList = function(value) {
  4040    return jspb.Message.setRepeatedWrapperField(this, 1, value);
  4041  };
  4042  
  4043  
  4044  /**
  4045   * @param {!proto.keys.KeyID=} opt_value
  4046   * @param {number=} opt_index
  4047   * @return {!proto.keys.KeyID}
  4048   */
  4049  proto.keys.ListResponse.prototype.addKey = function(opt_value, opt_index) {
  4050    return jspb.Message.addToRepeatedWrapperField(this, 1, opt_value, proto.keys.KeyID, opt_index);
  4051  };
  4052  
  4053  
  4054  /**
  4055   * Clears the list making it empty but non-null.
  4056   * @return {!proto.keys.ListResponse} returns this
  4057   */
  4058  proto.keys.ListResponse.prototype.clearKeyList = function() {
  4059    return this.setKeyList([]);
  4060  };
  4061  
  4062  
  4063  
  4064  
  4065  
  4066  if (jspb.Message.GENERATE_TO_OBJECT) {
  4067  /**
  4068   * Creates an object representation of this proto.
  4069   * Field names that are reserved in JavaScript and will be renamed to pb_name.
  4070   * Optional fields that are not set will be set to undefined.
  4071   * To access a reserved field use, foo.pb_<name>, eg, foo.pb_default.
  4072   * For the list of reserved names please see:
  4073   *     net/proto2/compiler/js/internal/generator.cc#kKeyword.
  4074   * @param {boolean=} opt_includeInstance Deprecated. whether to include the
  4075   *     JSPB instance for transitional soy proto support:
  4076   *     http://goto/soy-param-migration
  4077   * @return {!Object}
  4078   */
  4079  proto.keys.AddNameRequest.prototype.toObject = function(opt_includeInstance) {
  4080    return proto.keys.AddNameRequest.toObject(opt_includeInstance, this);
  4081  };
  4082  
  4083  
  4084  /**
  4085   * Static version of the {@see toObject} method.
  4086   * @param {boolean|undefined} includeInstance Deprecated. Whether to include
  4087   *     the JSPB instance for transitional soy proto support:
  4088   *     http://goto/soy-param-migration
  4089   * @param {!proto.keys.AddNameRequest} msg The msg instance to transform.
  4090   * @return {!Object}
  4091   * @suppress {unusedLocalVariables} f is only used for nested messages
  4092   */
  4093  proto.keys.AddNameRequest.toObject = function(includeInstance, msg) {
  4094    var f, obj = {
  4095      keyname: jspb.Message.getFieldWithDefault(msg, 1, ""),
  4096      address: jspb.Message.getFieldWithDefault(msg, 2, "")
  4097    };
  4098  
  4099    if (includeInstance) {
  4100      obj.$jspbMessageInstance = msg;
  4101    }
  4102    return obj;
  4103  };
  4104  }
  4105  
  4106  
  4107  /**
  4108   * Deserializes binary data (in protobuf wire format).
  4109   * @param {jspb.ByteSource} bytes The bytes to deserialize.
  4110   * @return {!proto.keys.AddNameRequest}
  4111   */
  4112  proto.keys.AddNameRequest.deserializeBinary = function(bytes) {
  4113    var reader = new jspb.BinaryReader(bytes);
  4114    var msg = new proto.keys.AddNameRequest;
  4115    return proto.keys.AddNameRequest.deserializeBinaryFromReader(msg, reader);
  4116  };
  4117  
  4118  
  4119  /**
  4120   * Deserializes binary data (in protobuf wire format) from the
  4121   * given reader into the given message object.
  4122   * @param {!proto.keys.AddNameRequest} msg The message object to deserialize into.
  4123   * @param {!jspb.BinaryReader} reader The BinaryReader to use.
  4124   * @return {!proto.keys.AddNameRequest}
  4125   */
  4126  proto.keys.AddNameRequest.deserializeBinaryFromReader = function(msg, reader) {
  4127    while (reader.nextField()) {
  4128      if (reader.isEndGroup()) {
  4129        break;
  4130      }
  4131      var field = reader.getFieldNumber();
  4132      switch (field) {
  4133      case 1:
  4134        var value = /** @type {string} */ (reader.readString());
  4135        msg.setKeyname(value);
  4136        break;
  4137      case 2:
  4138        var value = /** @type {string} */ (reader.readString());
  4139        msg.setAddress(value);
  4140        break;
  4141      default:
  4142        reader.skipField();
  4143        break;
  4144      }
  4145    }
  4146    return msg;
  4147  };
  4148  
  4149  
  4150  /**
  4151   * Serializes the message to binary data (in protobuf wire format).
  4152   * @return {!Uint8Array}
  4153   */
  4154  proto.keys.AddNameRequest.prototype.serializeBinary = function() {
  4155    var writer = new jspb.BinaryWriter();
  4156    proto.keys.AddNameRequest.serializeBinaryToWriter(this, writer);
  4157    return writer.getResultBuffer();
  4158  };
  4159  
  4160  
  4161  /**
  4162   * Serializes the given message to binary data (in protobuf wire
  4163   * format), writing to the given BinaryWriter.
  4164   * @param {!proto.keys.AddNameRequest} message
  4165   * @param {!jspb.BinaryWriter} writer
  4166   * @suppress {unusedLocalVariables} f is only used for nested messages
  4167   */
  4168  proto.keys.AddNameRequest.serializeBinaryToWriter = function(message, writer) {
  4169    var f = undefined;
  4170    f = message.getKeyname();
  4171    if (f.length > 0) {
  4172      writer.writeString(
  4173        1,
  4174        f
  4175      );
  4176    }
  4177    f = message.getAddress();
  4178    if (f.length > 0) {
  4179      writer.writeString(
  4180        2,
  4181        f
  4182      );
  4183    }
  4184  };
  4185  
  4186  
  4187  /**
  4188   * optional string Keyname = 1;
  4189   * @return {string}
  4190   */
  4191  proto.keys.AddNameRequest.prototype.getKeyname = function() {
  4192    return /** @type {string} */ (jspb.Message.getFieldWithDefault(this, 1, ""));
  4193  };
  4194  
  4195  
  4196  /**
  4197   * @param {string} value
  4198   * @return {!proto.keys.AddNameRequest} returns this
  4199   */
  4200  proto.keys.AddNameRequest.prototype.setKeyname = function(value) {
  4201    return jspb.Message.setProto3StringField(this, 1, value);
  4202  };
  4203  
  4204  
  4205  /**
  4206   * optional string Address = 2;
  4207   * @return {string}
  4208   */
  4209  proto.keys.AddNameRequest.prototype.getAddress = function() {
  4210    return /** @type {string} */ (jspb.Message.getFieldWithDefault(this, 2, ""));
  4211  };
  4212  
  4213  
  4214  /**
  4215   * @param {string} value
  4216   * @return {!proto.keys.AddNameRequest} returns this
  4217   */
  4218  proto.keys.AddNameRequest.prototype.setAddress = function(value) {
  4219    return jspb.Message.setProto3StringField(this, 2, value);
  4220  };
  4221  
  4222  
  4223  goog.object.extend(exports, proto.keys);