diff --git a/client/daemon_grpc_web_pb.js b/client/daemon_grpc_web_pb.js index 6d5cffb1..30cdd0c0 100644 --- a/client/daemon_grpc_web_pb.js +++ b/client/daemon_grpc_web_pb.js @@ -2585,5 +2585,310 @@ proto.daemon.DaemonPromiseClient.prototype.listCategories = }; +/** + * @const + * @type {!grpc.web.MethodDescriptor< + * !proto.daemon.SaveProfileRequest, + * !proto.daemon.ProfileStatus>} + */ +const methodDescriptor_Daemon_SaveProfile = new grpc.web.MethodDescriptor( + '/daemon.Daemon/SaveProfile', + grpc.web.MethodType.SERVER_STREAMING, + proto.daemon.SaveProfileRequest, + proto.daemon.ProfileStatus, + /** + * @param {!proto.daemon.SaveProfileRequest} request + * @return {!Uint8Array} + */ + function(request) { + return request.serializeBinary(); + }, + proto.daemon.ProfileStatus.deserializeBinary +); + + +/** + * @const + * @type {!grpc.web.AbstractClientBase.MethodInfo< + * !proto.daemon.SaveProfileRequest, + * !proto.daemon.ProfileStatus>} + */ +const methodInfo_Daemon_SaveProfile = new grpc.web.AbstractClientBase.MethodInfo( + proto.daemon.ProfileStatus, + /** + * @param {!proto.daemon.SaveProfileRequest} request + * @return {!Uint8Array} + */ + function(request) { + return request.serializeBinary(); + }, + proto.daemon.ProfileStatus.deserializeBinary +); + + +/** + * @param {!proto.daemon.SaveProfileRequest} request The request proto + * @param {?Object} metadata User defined + * call metadata + * @return {!grpc.web.ClientReadableStream} + * The XHR Node Readable Stream + */ +proto.daemon.DaemonClient.prototype.saveProfile = + function(request, metadata) { + return this.client_.serverStreaming(this.hostname_ + + '/daemon.Daemon/SaveProfile', + request, + metadata || {}, + methodDescriptor_Daemon_SaveProfile); +}; + + +/** + * @param {!proto.daemon.SaveProfileRequest} request The request proto + * @param {?Object} metadata User defined + * call metadata + * @return {!grpc.web.ClientReadableStream} + * The XHR Node Readable Stream + */ +proto.daemon.DaemonPromiseClient.prototype.saveProfile = + function(request, metadata) { + return this.client_.serverStreaming(this.hostname_ + + '/daemon.Daemon/SaveProfile', + request, + metadata || {}, + methodDescriptor_Daemon_SaveProfile); +}; + + +/** + * @const + * @type {!grpc.web.MethodDescriptor< + * !proto.daemon.DeleteProfileRequest, + * !proto.daemon.ProfileStatus>} + */ +const methodDescriptor_Daemon_DeleteProfile = new grpc.web.MethodDescriptor( + '/daemon.Daemon/DeleteProfile', + grpc.web.MethodType.SERVER_STREAMING, + proto.daemon.DeleteProfileRequest, + proto.daemon.ProfileStatus, + /** + * @param {!proto.daemon.DeleteProfileRequest} request + * @return {!Uint8Array} + */ + function(request) { + return request.serializeBinary(); + }, + proto.daemon.ProfileStatus.deserializeBinary +); + + +/** + * @const + * @type {!grpc.web.AbstractClientBase.MethodInfo< + * !proto.daemon.DeleteProfileRequest, + * !proto.daemon.ProfileStatus>} + */ +const methodInfo_Daemon_DeleteProfile = new grpc.web.AbstractClientBase.MethodInfo( + proto.daemon.ProfileStatus, + /** + * @param {!proto.daemon.DeleteProfileRequest} request + * @return {!Uint8Array} + */ + function(request) { + return request.serializeBinary(); + }, + proto.daemon.ProfileStatus.deserializeBinary +); + + +/** + * @param {!proto.daemon.DeleteProfileRequest} request The request proto + * @param {?Object} metadata User defined + * call metadata + * @return {!grpc.web.ClientReadableStream} + * The XHR Node Readable Stream + */ +proto.daemon.DaemonClient.prototype.deleteProfile = + function(request, metadata) { + return this.client_.serverStreaming(this.hostname_ + + '/daemon.Daemon/DeleteProfile', + request, + metadata || {}, + methodDescriptor_Daemon_DeleteProfile); +}; + + +/** + * @param {!proto.daemon.DeleteProfileRequest} request The request proto + * @param {?Object} metadata User defined + * call metadata + * @return {!grpc.web.ClientReadableStream} + * The XHR Node Readable Stream + */ +proto.daemon.DaemonPromiseClient.prototype.deleteProfile = + function(request, metadata) { + return this.client_.serverStreaming(this.hostname_ + + '/daemon.Daemon/DeleteProfile', + request, + metadata || {}, + methodDescriptor_Daemon_DeleteProfile); +}; + + +/** + * @const + * @type {!grpc.web.MethodDescriptor< + * !proto.daemon.SaveProfileRequest, + * !proto.daemon.ProfileStatus>} + */ +const methodDescriptor_Daemon_EditProfile = new grpc.web.MethodDescriptor( + '/daemon.Daemon/EditProfile', + grpc.web.MethodType.SERVER_STREAMING, + proto.daemon.SaveProfileRequest, + proto.daemon.ProfileStatus, + /** + * @param {!proto.daemon.SaveProfileRequest} request + * @return {!Uint8Array} + */ + function(request) { + return request.serializeBinary(); + }, + proto.daemon.ProfileStatus.deserializeBinary +); + + +/** + * @const + * @type {!grpc.web.AbstractClientBase.MethodInfo< + * !proto.daemon.SaveProfileRequest, + * !proto.daemon.ProfileStatus>} + */ +const methodInfo_Daemon_EditProfile = new grpc.web.AbstractClientBase.MethodInfo( + proto.daemon.ProfileStatus, + /** + * @param {!proto.daemon.SaveProfileRequest} request + * @return {!Uint8Array} + */ + function(request) { + return request.serializeBinary(); + }, + proto.daemon.ProfileStatus.deserializeBinary +); + + +/** + * @param {!proto.daemon.SaveProfileRequest} request The request proto + * @param {?Object} metadata User defined + * call metadata + * @return {!grpc.web.ClientReadableStream} + * The XHR Node Readable Stream + */ +proto.daemon.DaemonClient.prototype.editProfile = + function(request, metadata) { + return this.client_.serverStreaming(this.hostname_ + + '/daemon.Daemon/EditProfile', + request, + metadata || {}, + methodDescriptor_Daemon_EditProfile); +}; + + +/** + * @param {!proto.daemon.SaveProfileRequest} request The request proto + * @param {?Object} metadata User defined + * call metadata + * @return {!grpc.web.ClientReadableStream} + * The XHR Node Readable Stream + */ +proto.daemon.DaemonPromiseClient.prototype.editProfile = + function(request, metadata) { + return this.client_.serverStreaming(this.hostname_ + + '/daemon.Daemon/EditProfile', + request, + metadata || {}, + methodDescriptor_Daemon_EditProfile); +}; + + +/** + * @const + * @type {!grpc.web.MethodDescriptor< + * !proto.daemon.Empty, + * !proto.daemon.ListProfilesResponse>} + */ +const methodDescriptor_Daemon_ListProfiles = new grpc.web.MethodDescriptor( + '/daemon.Daemon/ListProfiles', + grpc.web.MethodType.UNARY, + proto.daemon.Empty, + proto.daemon.ListProfilesResponse, + /** + * @param {!proto.daemon.Empty} request + * @return {!Uint8Array} + */ + function(request) { + return request.serializeBinary(); + }, + proto.daemon.ListProfilesResponse.deserializeBinary +); + + +/** + * @const + * @type {!grpc.web.AbstractClientBase.MethodInfo< + * !proto.daemon.Empty, + * !proto.daemon.ListProfilesResponse>} + */ +const methodInfo_Daemon_ListProfiles = new grpc.web.AbstractClientBase.MethodInfo( + proto.daemon.ListProfilesResponse, + /** + * @param {!proto.daemon.Empty} request + * @return {!Uint8Array} + */ + function(request) { + return request.serializeBinary(); + }, + proto.daemon.ListProfilesResponse.deserializeBinary +); + + +/** + * @param {!proto.daemon.Empty} request The + * request proto + * @param {?Object} metadata User defined + * call metadata + * @param {function(?grpc.web.Error, ?proto.daemon.ListProfilesResponse)} + * callback The callback function(error, response) + * @return {!grpc.web.ClientReadableStream|undefined} + * The XHR Node Readable Stream + */ +proto.daemon.DaemonClient.prototype.listProfiles = + function(request, metadata, callback) { + return this.client_.rpcCall(this.hostname_ + + '/daemon.Daemon/ListProfiles', + request, + metadata || {}, + methodDescriptor_Daemon_ListProfiles, + callback); +}; + + +/** + * @param {!proto.daemon.Empty} request The + * request proto + * @param {?Object} metadata User defined + * call metadata + * @return {!Promise} + * Promise that resolves to the response + */ +proto.daemon.DaemonPromiseClient.prototype.listProfiles = + function(request, metadata) { + return this.client_.unaryCall(this.hostname_ + + '/daemon.Daemon/ListProfiles', + request, + metadata || {}, + methodDescriptor_Daemon_ListProfiles); +}; + + module.exports = proto.daemon; diff --git a/client/daemon_pb.js b/client/daemon_pb.js index b43c35e7..251d6f20 100644 --- a/client/daemon_pb.js +++ b/client/daemon_pb.js @@ -17,6 +17,7 @@ goog.exportSymbol('proto.daemon.AddNotificationRequest', null, global); goog.exportSymbol('proto.daemon.AddNotificationResponse', null, global); goog.exportSymbol('proto.daemon.CreateEventRequest', null, global); goog.exportSymbol('proto.daemon.CredsResponse', null, global); +goog.exportSymbol('proto.daemon.DeleteProfileRequest', null, global); goog.exportSymbol('proto.daemon.DeleteTeamRequest', null, global); goog.exportSymbol('proto.daemon.DeleteTeamResponse', null, global); goog.exportSymbol('proto.daemon.DestroyUserRequest', null, global); @@ -46,15 +47,21 @@ goog.exportSymbol('proto.daemon.ListExercisesResponse.Exercise', null, global); goog.exportSymbol('proto.daemon.ListExercisesResponse.Exercise.ExerciseInfo', null, global); goog.exportSymbol('proto.daemon.ListFrontendsResponse', null, global); goog.exportSymbol('proto.daemon.ListFrontendsResponse.Frontend', null, global); +goog.exportSymbol('proto.daemon.ListProfilesResponse', null, global); +goog.exportSymbol('proto.daemon.ListProfilesResponse.Profile', null, global); +goog.exportSymbol('proto.daemon.ListProfilesResponse.Profile.Challenge', null, global); goog.exportSymbol('proto.daemon.ListUsersResponse', null, global); goog.exportSymbol('proto.daemon.ListUsersResponse.UserInfo', null, global); goog.exportSymbol('proto.daemon.LoginUserRequest', null, global); goog.exportSymbol('proto.daemon.LoginUserResponse', null, global); goog.exportSymbol('proto.daemon.MonitorHostResponse', null, global); +goog.exportSymbol('proto.daemon.ProfileStatus', null, global); goog.exportSymbol('proto.daemon.ResetExerciseRequest', null, global); goog.exportSymbol('proto.daemon.ResetFrontendsRequest', null, global); goog.exportSymbol('proto.daemon.ResetTeamStatus', null, global); goog.exportSymbol('proto.daemon.RestartTeamLabRequest', null, global); +goog.exportSymbol('proto.daemon.SaveProfileRequest', null, global); +goog.exportSymbol('proto.daemon.SaveProfileRequest.Challenge', null, global); goog.exportSymbol('proto.daemon.SetFrontendCpuRequest', null, global); goog.exportSymbol('proto.daemon.SetFrontendMemoryRequest', null, global); goog.exportSymbol('proto.daemon.SetTeamSuspendRequest', null, global); @@ -5392,7 +5399,7 @@ proto.daemon.CreateEventRequest.toObject = function(includeInstance, msg) { capacity: jspb.Message.getFieldWithDefault(msg, 6, 0), starttime: jspb.Message.getFieldWithDefault(msg, 7, ""), finishtime: jspb.Message.getFieldWithDefault(msg, 8, ""), - onlyvpn: jspb.Message.getFieldWithDefault(msg, 9, false), + onlyvpn: jspb.Message.getFieldWithDefault(msg, 9, 0), secretevent: jspb.Message.getFieldWithDefault(msg, 10, ""), disableexercisesList: jspb.Message.getRepeatedField(msg, 11) }; @@ -5464,7 +5471,7 @@ proto.daemon.CreateEventRequest.deserializeBinaryFromReader = function(msg, read msg.setFinishtime(value); break; case 9: - var value = /** @type {boolean} */ (reader.readBool()); + var value = /** @type {number} */ (reader.readInt32()); msg.setOnlyvpn(value); break; case 10: @@ -5561,8 +5568,8 @@ proto.daemon.CreateEventRequest.serializeBinaryToWriter = function(message, writ ); } f = message.getOnlyvpn(); - if (f) { - writer.writeBool( + if (f !== 0) { + writer.writeInt32( 9, f ); @@ -5733,19 +5740,17 @@ proto.daemon.CreateEventRequest.prototype.setFinishtime = function(value) { /** - * optional bool onlyVPN = 9; - * Note that Boolean fields may be set to 0/1 when serialized from a Java server. - * You should avoid comparisons like {@code val === true/false} in those cases. - * @return {boolean} + * optional int32 onlyVPN = 9; + * @return {number} */ proto.daemon.CreateEventRequest.prototype.getOnlyvpn = function() { - return /** @type {boolean} */ (jspb.Message.getFieldWithDefault(this, 9, false)); + return /** @type {number} */ (jspb.Message.getFieldWithDefault(this, 9, 0)); }; -/** @param {boolean} value */ +/** @param {number} value */ proto.daemon.CreateEventRequest.prototype.setOnlyvpn = function(value) { - jspb.Message.setProto3BooleanField(this, 9, value); + jspb.Message.setProto3IntField(this, 9, value); }; @@ -8515,6 +8520,1271 @@ proto.daemon.ListExercisesResponse.prototype.clearExercisesList = function() { +/** + * Generated by JsPbCodeGenerator. + * @param {Array=} opt_data Optional initial data array, typically from a + * server response, or constructed directly in Javascript. The array is used + * in place and becomes part of the constructed object. It is not cloned. + * If no data is provided, the constructed object will be empty, but still + * valid. + * @extends {jspb.Message} + * @constructor + */ +proto.daemon.ListProfilesResponse = function(opt_data) { + jspb.Message.initialize(this, opt_data, 0, -1, proto.daemon.ListProfilesResponse.repeatedFields_, null); +}; +goog.inherits(proto.daemon.ListProfilesResponse, jspb.Message); +if (goog.DEBUG && !COMPILED) { + proto.daemon.ListProfilesResponse.displayName = 'proto.daemon.ListProfilesResponse'; +} +/** + * List of repeated fields within this message type. + * @private {!Array} + * @const + */ +proto.daemon.ListProfilesResponse.repeatedFields_ = [1]; + + + +if (jspb.Message.GENERATE_TO_OBJECT) { +/** + * Creates an object representation of this proto suitable for use in Soy templates. + * Field names that are reserved in JavaScript and will be renamed to pb_name. + * To access a reserved field use, foo.pb_, eg, foo.pb_default. + * For the list of reserved names please see: + * com.google.apps.jspb.JsClassTemplate.JS_RESERVED_WORDS. + * @param {boolean=} opt_includeInstance Whether to include the JSPB instance + * for transitional soy proto support: http://goto/soy-param-migration + * @return {!Object} + */ +proto.daemon.ListProfilesResponse.prototype.toObject = function(opt_includeInstance) { + return proto.daemon.ListProfilesResponse.toObject(opt_includeInstance, this); +}; + + +/** + * Static version of the {@see toObject} method. + * @param {boolean|undefined} includeInstance Whether to include the JSPB + * instance for transitional soy proto support: + * http://goto/soy-param-migration + * @param {!proto.daemon.ListProfilesResponse} msg The msg instance to transform. + * @return {!Object} + * @suppress {unusedLocalVariables} f is only used for nested messages + */ +proto.daemon.ListProfilesResponse.toObject = function(includeInstance, msg) { + var f, obj = { + profilesList: jspb.Message.toObjectList(msg.getProfilesList(), + proto.daemon.ListProfilesResponse.Profile.toObject, includeInstance) + }; + + if (includeInstance) { + obj.$jspbMessageInstance = msg; + } + return obj; +}; +} + + +/** + * Deserializes binary data (in protobuf wire format). + * @param {jspb.ByteSource} bytes The bytes to deserialize. + * @return {!proto.daemon.ListProfilesResponse} + */ +proto.daemon.ListProfilesResponse.deserializeBinary = function(bytes) { + var reader = new jspb.BinaryReader(bytes); + var msg = new proto.daemon.ListProfilesResponse; + return proto.daemon.ListProfilesResponse.deserializeBinaryFromReader(msg, reader); +}; + + +/** + * Deserializes binary data (in protobuf wire format) from the + * given reader into the given message object. + * @param {!proto.daemon.ListProfilesResponse} msg The message object to deserialize into. + * @param {!jspb.BinaryReader} reader The BinaryReader to use. + * @return {!proto.daemon.ListProfilesResponse} + */ +proto.daemon.ListProfilesResponse.deserializeBinaryFromReader = function(msg, reader) { + while (reader.nextField()) { + if (reader.isEndGroup()) { + break; + } + var field = reader.getFieldNumber(); + switch (field) { + case 1: + var value = new proto.daemon.ListProfilesResponse.Profile; + reader.readMessage(value,proto.daemon.ListProfilesResponse.Profile.deserializeBinaryFromReader); + msg.addProfiles(value); + break; + default: + reader.skipField(); + break; + } + } + return msg; +}; + + +/** + * Serializes the message to binary data (in protobuf wire format). + * @return {!Uint8Array} + */ +proto.daemon.ListProfilesResponse.prototype.serializeBinary = function() { + var writer = new jspb.BinaryWriter(); + proto.daemon.ListProfilesResponse.serializeBinaryToWriter(this, writer); + return writer.getResultBuffer(); +}; + + +/** + * Serializes the given message to binary data (in protobuf wire + * format), writing to the given BinaryWriter. + * @param {!proto.daemon.ListProfilesResponse} message + * @param {!jspb.BinaryWriter} writer + * @suppress {unusedLocalVariables} f is only used for nested messages + */ +proto.daemon.ListProfilesResponse.serializeBinaryToWriter = function(message, writer) { + var f = undefined; + f = message.getProfilesList(); + if (f.length > 0) { + writer.writeRepeatedMessage( + 1, + f, + proto.daemon.ListProfilesResponse.Profile.serializeBinaryToWriter + ); + } +}; + + + +/** + * Generated by JsPbCodeGenerator. + * @param {Array=} opt_data Optional initial data array, typically from a + * server response, or constructed directly in Javascript. The array is used + * in place and becomes part of the constructed object. It is not cloned. + * If no data is provided, the constructed object will be empty, but still + * valid. + * @extends {jspb.Message} + * @constructor + */ +proto.daemon.ListProfilesResponse.Profile = function(opt_data) { + jspb.Message.initialize(this, opt_data, 0, -1, proto.daemon.ListProfilesResponse.Profile.repeatedFields_, null); +}; +goog.inherits(proto.daemon.ListProfilesResponse.Profile, jspb.Message); +if (goog.DEBUG && !COMPILED) { + proto.daemon.ListProfilesResponse.Profile.displayName = 'proto.daemon.ListProfilesResponse.Profile'; +} +/** + * List of repeated fields within this message type. + * @private {!Array} + * @const + */ +proto.daemon.ListProfilesResponse.Profile.repeatedFields_ = [3]; + + + +if (jspb.Message.GENERATE_TO_OBJECT) { +/** + * Creates an object representation of this proto suitable for use in Soy templates. + * Field names that are reserved in JavaScript and will be renamed to pb_name. + * To access a reserved field use, foo.pb_, eg, foo.pb_default. + * For the list of reserved names please see: + * com.google.apps.jspb.JsClassTemplate.JS_RESERVED_WORDS. + * @param {boolean=} opt_includeInstance Whether to include the JSPB instance + * for transitional soy proto support: http://goto/soy-param-migration + * @return {!Object} + */ +proto.daemon.ListProfilesResponse.Profile.prototype.toObject = function(opt_includeInstance) { + return proto.daemon.ListProfilesResponse.Profile.toObject(opt_includeInstance, this); +}; + + +/** + * Static version of the {@see toObject} method. + * @param {boolean|undefined} includeInstance Whether to include the JSPB + * instance for transitional soy proto support: + * http://goto/soy-param-migration + * @param {!proto.daemon.ListProfilesResponse.Profile} msg The msg instance to transform. + * @return {!Object} + * @suppress {unusedLocalVariables} f is only used for nested messages + */ +proto.daemon.ListProfilesResponse.Profile.toObject = function(includeInstance, msg) { + var f, obj = { + name: jspb.Message.getFieldWithDefault(msg, 1, ""), + secret: jspb.Message.getFieldWithDefault(msg, 2, false), + challengesList: jspb.Message.toObjectList(msg.getChallengesList(), + proto.daemon.ListProfilesResponse.Profile.Challenge.toObject, includeInstance) + }; + + if (includeInstance) { + obj.$jspbMessageInstance = msg; + } + return obj; +}; +} + + +/** + * Deserializes binary data (in protobuf wire format). + * @param {jspb.ByteSource} bytes The bytes to deserialize. + * @return {!proto.daemon.ListProfilesResponse.Profile} + */ +proto.daemon.ListProfilesResponse.Profile.deserializeBinary = function(bytes) { + var reader = new jspb.BinaryReader(bytes); + var msg = new proto.daemon.ListProfilesResponse.Profile; + return proto.daemon.ListProfilesResponse.Profile.deserializeBinaryFromReader(msg, reader); +}; + + +/** + * Deserializes binary data (in protobuf wire format) from the + * given reader into the given message object. + * @param {!proto.daemon.ListProfilesResponse.Profile} msg The message object to deserialize into. + * @param {!jspb.BinaryReader} reader The BinaryReader to use. + * @return {!proto.daemon.ListProfilesResponse.Profile} + */ +proto.daemon.ListProfilesResponse.Profile.deserializeBinaryFromReader = function(msg, reader) { + while (reader.nextField()) { + if (reader.isEndGroup()) { + break; + } + var field = reader.getFieldNumber(); + switch (field) { + case 1: + var value = /** @type {string} */ (reader.readString()); + msg.setName(value); + break; + case 2: + var value = /** @type {boolean} */ (reader.readBool()); + msg.setSecret(value); + break; + case 3: + var value = new proto.daemon.ListProfilesResponse.Profile.Challenge; + reader.readMessage(value,proto.daemon.ListProfilesResponse.Profile.Challenge.deserializeBinaryFromReader); + msg.addChallenges(value); + break; + default: + reader.skipField(); + break; + } + } + return msg; +}; + + +/** + * Serializes the message to binary data (in protobuf wire format). + * @return {!Uint8Array} + */ +proto.daemon.ListProfilesResponse.Profile.prototype.serializeBinary = function() { + var writer = new jspb.BinaryWriter(); + proto.daemon.ListProfilesResponse.Profile.serializeBinaryToWriter(this, writer); + return writer.getResultBuffer(); +}; + + +/** + * Serializes the given message to binary data (in protobuf wire + * format), writing to the given BinaryWriter. + * @param {!proto.daemon.ListProfilesResponse.Profile} message + * @param {!jspb.BinaryWriter} writer + * @suppress {unusedLocalVariables} f is only used for nested messages + */ +proto.daemon.ListProfilesResponse.Profile.serializeBinaryToWriter = function(message, writer) { + var f = undefined; + f = message.getName(); + if (f.length > 0) { + writer.writeString( + 1, + f + ); + } + f = message.getSecret(); + if (f) { + writer.writeBool( + 2, + f + ); + } + f = message.getChallengesList(); + if (f.length > 0) { + writer.writeRepeatedMessage( + 3, + f, + proto.daemon.ListProfilesResponse.Profile.Challenge.serializeBinaryToWriter + ); + } +}; + + + +/** + * Generated by JsPbCodeGenerator. + * @param {Array=} opt_data Optional initial data array, typically from a + * server response, or constructed directly in Javascript. The array is used + * in place and becomes part of the constructed object. It is not cloned. + * If no data is provided, the constructed object will be empty, but still + * valid. + * @extends {jspb.Message} + * @constructor + */ +proto.daemon.ListProfilesResponse.Profile.Challenge = function(opt_data) { + jspb.Message.initialize(this, opt_data, 0, -1, null, null); +}; +goog.inherits(proto.daemon.ListProfilesResponse.Profile.Challenge, jspb.Message); +if (goog.DEBUG && !COMPILED) { + proto.daemon.ListProfilesResponse.Profile.Challenge.displayName = 'proto.daemon.ListProfilesResponse.Profile.Challenge'; +} + + +if (jspb.Message.GENERATE_TO_OBJECT) { +/** + * Creates an object representation of this proto suitable for use in Soy templates. + * Field names that are reserved in JavaScript and will be renamed to pb_name. + * To access a reserved field use, foo.pb_, eg, foo.pb_default. + * For the list of reserved names please see: + * com.google.apps.jspb.JsClassTemplate.JS_RESERVED_WORDS. + * @param {boolean=} opt_includeInstance Whether to include the JSPB instance + * for transitional soy proto support: http://goto/soy-param-migration + * @return {!Object} + */ +proto.daemon.ListProfilesResponse.Profile.Challenge.prototype.toObject = function(opt_includeInstance) { + return proto.daemon.ListProfilesResponse.Profile.Challenge.toObject(opt_includeInstance, this); +}; + + +/** + * Static version of the {@see toObject} method. + * @param {boolean|undefined} includeInstance Whether to include the JSPB + * instance for transitional soy proto support: + * http://goto/soy-param-migration + * @param {!proto.daemon.ListProfilesResponse.Profile.Challenge} msg The msg instance to transform. + * @return {!Object} + * @suppress {unusedLocalVariables} f is only used for nested messages + */ +proto.daemon.ListProfilesResponse.Profile.Challenge.toObject = function(includeInstance, msg) { + var f, obj = { + tag: jspb.Message.getFieldWithDefault(msg, 1, ""), + name: jspb.Message.getFieldWithDefault(msg, 2, "") + }; + + if (includeInstance) { + obj.$jspbMessageInstance = msg; + } + return obj; +}; +} + + +/** + * Deserializes binary data (in protobuf wire format). + * @param {jspb.ByteSource} bytes The bytes to deserialize. + * @return {!proto.daemon.ListProfilesResponse.Profile.Challenge} + */ +proto.daemon.ListProfilesResponse.Profile.Challenge.deserializeBinary = function(bytes) { + var reader = new jspb.BinaryReader(bytes); + var msg = new proto.daemon.ListProfilesResponse.Profile.Challenge; + return proto.daemon.ListProfilesResponse.Profile.Challenge.deserializeBinaryFromReader(msg, reader); +}; + + +/** + * Deserializes binary data (in protobuf wire format) from the + * given reader into the given message object. + * @param {!proto.daemon.ListProfilesResponse.Profile.Challenge} msg The message object to deserialize into. + * @param {!jspb.BinaryReader} reader The BinaryReader to use. + * @return {!proto.daemon.ListProfilesResponse.Profile.Challenge} + */ +proto.daemon.ListProfilesResponse.Profile.Challenge.deserializeBinaryFromReader = function(msg, reader) { + while (reader.nextField()) { + if (reader.isEndGroup()) { + break; + } + var field = reader.getFieldNumber(); + switch (field) { + case 1: + var value = /** @type {string} */ (reader.readString()); + msg.setTag(value); + break; + case 2: + var value = /** @type {string} */ (reader.readString()); + msg.setName(value); + break; + default: + reader.skipField(); + break; + } + } + return msg; +}; + + +/** + * Serializes the message to binary data (in protobuf wire format). + * @return {!Uint8Array} + */ +proto.daemon.ListProfilesResponse.Profile.Challenge.prototype.serializeBinary = function() { + var writer = new jspb.BinaryWriter(); + proto.daemon.ListProfilesResponse.Profile.Challenge.serializeBinaryToWriter(this, writer); + return writer.getResultBuffer(); +}; + + +/** + * Serializes the given message to binary data (in protobuf wire + * format), writing to the given BinaryWriter. + * @param {!proto.daemon.ListProfilesResponse.Profile.Challenge} message + * @param {!jspb.BinaryWriter} writer + * @suppress {unusedLocalVariables} f is only used for nested messages + */ +proto.daemon.ListProfilesResponse.Profile.Challenge.serializeBinaryToWriter = function(message, writer) { + var f = undefined; + f = message.getTag(); + if (f.length > 0) { + writer.writeString( + 1, + f + ); + } + f = message.getName(); + if (f.length > 0) { + writer.writeString( + 2, + f + ); + } +}; + + +/** + * optional string tag = 1; + * @return {string} + */ +proto.daemon.ListProfilesResponse.Profile.Challenge.prototype.getTag = function() { + return /** @type {string} */ (jspb.Message.getFieldWithDefault(this, 1, "")); +}; + + +/** @param {string} value */ +proto.daemon.ListProfilesResponse.Profile.Challenge.prototype.setTag = function(value) { + jspb.Message.setProto3StringField(this, 1, value); +}; + + +/** + * optional string name = 2; + * @return {string} + */ +proto.daemon.ListProfilesResponse.Profile.Challenge.prototype.getName = function() { + return /** @type {string} */ (jspb.Message.getFieldWithDefault(this, 2, "")); +}; + + +/** @param {string} value */ +proto.daemon.ListProfilesResponse.Profile.Challenge.prototype.setName = function(value) { + jspb.Message.setProto3StringField(this, 2, value); +}; + + +/** + * optional string name = 1; + * @return {string} + */ +proto.daemon.ListProfilesResponse.Profile.prototype.getName = function() { + return /** @type {string} */ (jspb.Message.getFieldWithDefault(this, 1, "")); +}; + + +/** @param {string} value */ +proto.daemon.ListProfilesResponse.Profile.prototype.setName = function(value) { + jspb.Message.setProto3StringField(this, 1, value); +}; + + +/** + * optional bool secret = 2; + * Note that Boolean fields may be set to 0/1 when serialized from a Java server. + * You should avoid comparisons like {@code val === true/false} in those cases. + * @return {boolean} + */ +proto.daemon.ListProfilesResponse.Profile.prototype.getSecret = function() { + return /** @type {boolean} */ (jspb.Message.getFieldWithDefault(this, 2, false)); +}; + + +/** @param {boolean} value */ +proto.daemon.ListProfilesResponse.Profile.prototype.setSecret = function(value) { + jspb.Message.setProto3BooleanField(this, 2, value); +}; + + +/** + * repeated Challenge challenges = 3; + * @return {!Array} + */ +proto.daemon.ListProfilesResponse.Profile.prototype.getChallengesList = function() { + return /** @type{!Array} */ ( + jspb.Message.getRepeatedWrapperField(this, proto.daemon.ListProfilesResponse.Profile.Challenge, 3)); +}; + + +/** @param {!Array} value */ +proto.daemon.ListProfilesResponse.Profile.prototype.setChallengesList = function(value) { + jspb.Message.setRepeatedWrapperField(this, 3, value); +}; + + +/** + * @param {!proto.daemon.ListProfilesResponse.Profile.Challenge=} opt_value + * @param {number=} opt_index + * @return {!proto.daemon.ListProfilesResponse.Profile.Challenge} + */ +proto.daemon.ListProfilesResponse.Profile.prototype.addChallenges = function(opt_value, opt_index) { + return jspb.Message.addToRepeatedWrapperField(this, 3, opt_value, proto.daemon.ListProfilesResponse.Profile.Challenge, opt_index); +}; + + +proto.daemon.ListProfilesResponse.Profile.prototype.clearChallengesList = function() { + this.setChallengesList([]); +}; + + +/** + * repeated Profile profiles = 1; + * @return {!Array} + */ +proto.daemon.ListProfilesResponse.prototype.getProfilesList = function() { + return /** @type{!Array} */ ( + jspb.Message.getRepeatedWrapperField(this, proto.daemon.ListProfilesResponse.Profile, 1)); +}; + + +/** @param {!Array} value */ +proto.daemon.ListProfilesResponse.prototype.setProfilesList = function(value) { + jspb.Message.setRepeatedWrapperField(this, 1, value); +}; + + +/** + * @param {!proto.daemon.ListProfilesResponse.Profile=} opt_value + * @param {number=} opt_index + * @return {!proto.daemon.ListProfilesResponse.Profile} + */ +proto.daemon.ListProfilesResponse.prototype.addProfiles = function(opt_value, opt_index) { + return jspb.Message.addToRepeatedWrapperField(this, 1, opt_value, proto.daemon.ListProfilesResponse.Profile, opt_index); +}; + + +proto.daemon.ListProfilesResponse.prototype.clearProfilesList = function() { + this.setProfilesList([]); +}; + + + +/** + * Generated by JsPbCodeGenerator. + * @param {Array=} opt_data Optional initial data array, typically from a + * server response, or constructed directly in Javascript. The array is used + * in place and becomes part of the constructed object. It is not cloned. + * If no data is provided, the constructed object will be empty, but still + * valid. + * @extends {jspb.Message} + * @constructor + */ +proto.daemon.SaveProfileRequest = function(opt_data) { + jspb.Message.initialize(this, opt_data, 0, -1, proto.daemon.SaveProfileRequest.repeatedFields_, null); +}; +goog.inherits(proto.daemon.SaveProfileRequest, jspb.Message); +if (goog.DEBUG && !COMPILED) { + proto.daemon.SaveProfileRequest.displayName = 'proto.daemon.SaveProfileRequest'; +} +/** + * List of repeated fields within this message type. + * @private {!Array} + * @const + */ +proto.daemon.SaveProfileRequest.repeatedFields_ = [3]; + + + +if (jspb.Message.GENERATE_TO_OBJECT) { +/** + * Creates an object representation of this proto suitable for use in Soy templates. + * Field names that are reserved in JavaScript and will be renamed to pb_name. + * To access a reserved field use, foo.pb_, eg, foo.pb_default. + * For the list of reserved names please see: + * com.google.apps.jspb.JsClassTemplate.JS_RESERVED_WORDS. + * @param {boolean=} opt_includeInstance Whether to include the JSPB instance + * for transitional soy proto support: http://goto/soy-param-migration + * @return {!Object} + */ +proto.daemon.SaveProfileRequest.prototype.toObject = function(opt_includeInstance) { + return proto.daemon.SaveProfileRequest.toObject(opt_includeInstance, this); +}; + + +/** + * Static version of the {@see toObject} method. + * @param {boolean|undefined} includeInstance Whether to include the JSPB + * instance for transitional soy proto support: + * http://goto/soy-param-migration + * @param {!proto.daemon.SaveProfileRequest} msg The msg instance to transform. + * @return {!Object} + * @suppress {unusedLocalVariables} f is only used for nested messages + */ +proto.daemon.SaveProfileRequest.toObject = function(includeInstance, msg) { + var f, obj = { + name: jspb.Message.getFieldWithDefault(msg, 1, ""), + secret: jspb.Message.getFieldWithDefault(msg, 2, false), + challengesList: jspb.Message.toObjectList(msg.getChallengesList(), + proto.daemon.SaveProfileRequest.Challenge.toObject, includeInstance) + }; + + if (includeInstance) { + obj.$jspbMessageInstance = msg; + } + return obj; +}; +} + + +/** + * Deserializes binary data (in protobuf wire format). + * @param {jspb.ByteSource} bytes The bytes to deserialize. + * @return {!proto.daemon.SaveProfileRequest} + */ +proto.daemon.SaveProfileRequest.deserializeBinary = function(bytes) { + var reader = new jspb.BinaryReader(bytes); + var msg = new proto.daemon.SaveProfileRequest; + return proto.daemon.SaveProfileRequest.deserializeBinaryFromReader(msg, reader); +}; + + +/** + * Deserializes binary data (in protobuf wire format) from the + * given reader into the given message object. + * @param {!proto.daemon.SaveProfileRequest} msg The message object to deserialize into. + * @param {!jspb.BinaryReader} reader The BinaryReader to use. + * @return {!proto.daemon.SaveProfileRequest} + */ +proto.daemon.SaveProfileRequest.deserializeBinaryFromReader = function(msg, reader) { + while (reader.nextField()) { + if (reader.isEndGroup()) { + break; + } + var field = reader.getFieldNumber(); + switch (field) { + case 1: + var value = /** @type {string} */ (reader.readString()); + msg.setName(value); + break; + case 2: + var value = /** @type {boolean} */ (reader.readBool()); + msg.setSecret(value); + break; + case 3: + var value = new proto.daemon.SaveProfileRequest.Challenge; + reader.readMessage(value,proto.daemon.SaveProfileRequest.Challenge.deserializeBinaryFromReader); + msg.addChallenges(value); + break; + default: + reader.skipField(); + break; + } + } + return msg; +}; + + +/** + * Serializes the message to binary data (in protobuf wire format). + * @return {!Uint8Array} + */ +proto.daemon.SaveProfileRequest.prototype.serializeBinary = function() { + var writer = new jspb.BinaryWriter(); + proto.daemon.SaveProfileRequest.serializeBinaryToWriter(this, writer); + return writer.getResultBuffer(); +}; + + +/** + * Serializes the given message to binary data (in protobuf wire + * format), writing to the given BinaryWriter. + * @param {!proto.daemon.SaveProfileRequest} message + * @param {!jspb.BinaryWriter} writer + * @suppress {unusedLocalVariables} f is only used for nested messages + */ +proto.daemon.SaveProfileRequest.serializeBinaryToWriter = function(message, writer) { + var f = undefined; + f = message.getName(); + if (f.length > 0) { + writer.writeString( + 1, + f + ); + } + f = message.getSecret(); + if (f) { + writer.writeBool( + 2, + f + ); + } + f = message.getChallengesList(); + if (f.length > 0) { + writer.writeRepeatedMessage( + 3, + f, + proto.daemon.SaveProfileRequest.Challenge.serializeBinaryToWriter + ); + } +}; + + + +/** + * Generated by JsPbCodeGenerator. + * @param {Array=} opt_data Optional initial data array, typically from a + * server response, or constructed directly in Javascript. The array is used + * in place and becomes part of the constructed object. It is not cloned. + * If no data is provided, the constructed object will be empty, but still + * valid. + * @extends {jspb.Message} + * @constructor + */ +proto.daemon.SaveProfileRequest.Challenge = function(opt_data) { + jspb.Message.initialize(this, opt_data, 0, -1, null, null); +}; +goog.inherits(proto.daemon.SaveProfileRequest.Challenge, jspb.Message); +if (goog.DEBUG && !COMPILED) { + proto.daemon.SaveProfileRequest.Challenge.displayName = 'proto.daemon.SaveProfileRequest.Challenge'; +} + + +if (jspb.Message.GENERATE_TO_OBJECT) { +/** + * Creates an object representation of this proto suitable for use in Soy templates. + * Field names that are reserved in JavaScript and will be renamed to pb_name. + * To access a reserved field use, foo.pb_, eg, foo.pb_default. + * For the list of reserved names please see: + * com.google.apps.jspb.JsClassTemplate.JS_RESERVED_WORDS. + * @param {boolean=} opt_includeInstance Whether to include the JSPB instance + * for transitional soy proto support: http://goto/soy-param-migration + * @return {!Object} + */ +proto.daemon.SaveProfileRequest.Challenge.prototype.toObject = function(opt_includeInstance) { + return proto.daemon.SaveProfileRequest.Challenge.toObject(opt_includeInstance, this); +}; + + +/** + * Static version of the {@see toObject} method. + * @param {boolean|undefined} includeInstance Whether to include the JSPB + * instance for transitional soy proto support: + * http://goto/soy-param-migration + * @param {!proto.daemon.SaveProfileRequest.Challenge} msg The msg instance to transform. + * @return {!Object} + * @suppress {unusedLocalVariables} f is only used for nested messages + */ +proto.daemon.SaveProfileRequest.Challenge.toObject = function(includeInstance, msg) { + var f, obj = { + tag: jspb.Message.getFieldWithDefault(msg, 1, ""), + name: jspb.Message.getFieldWithDefault(msg, 2, "") + }; + + if (includeInstance) { + obj.$jspbMessageInstance = msg; + } + return obj; +}; +} + + +/** + * Deserializes binary data (in protobuf wire format). + * @param {jspb.ByteSource} bytes The bytes to deserialize. + * @return {!proto.daemon.SaveProfileRequest.Challenge} + */ +proto.daemon.SaveProfileRequest.Challenge.deserializeBinary = function(bytes) { + var reader = new jspb.BinaryReader(bytes); + var msg = new proto.daemon.SaveProfileRequest.Challenge; + return proto.daemon.SaveProfileRequest.Challenge.deserializeBinaryFromReader(msg, reader); +}; + + +/** + * Deserializes binary data (in protobuf wire format) from the + * given reader into the given message object. + * @param {!proto.daemon.SaveProfileRequest.Challenge} msg The message object to deserialize into. + * @param {!jspb.BinaryReader} reader The BinaryReader to use. + * @return {!proto.daemon.SaveProfileRequest.Challenge} + */ +proto.daemon.SaveProfileRequest.Challenge.deserializeBinaryFromReader = function(msg, reader) { + while (reader.nextField()) { + if (reader.isEndGroup()) { + break; + } + var field = reader.getFieldNumber(); + switch (field) { + case 1: + var value = /** @type {string} */ (reader.readString()); + msg.setTag(value); + break; + case 2: + var value = /** @type {string} */ (reader.readString()); + msg.setName(value); + break; + default: + reader.skipField(); + break; + } + } + return msg; +}; + + +/** + * Serializes the message to binary data (in protobuf wire format). + * @return {!Uint8Array} + */ +proto.daemon.SaveProfileRequest.Challenge.prototype.serializeBinary = function() { + var writer = new jspb.BinaryWriter(); + proto.daemon.SaveProfileRequest.Challenge.serializeBinaryToWriter(this, writer); + return writer.getResultBuffer(); +}; + + +/** + * Serializes the given message to binary data (in protobuf wire + * format), writing to the given BinaryWriter. + * @param {!proto.daemon.SaveProfileRequest.Challenge} message + * @param {!jspb.BinaryWriter} writer + * @suppress {unusedLocalVariables} f is only used for nested messages + */ +proto.daemon.SaveProfileRequest.Challenge.serializeBinaryToWriter = function(message, writer) { + var f = undefined; + f = message.getTag(); + if (f.length > 0) { + writer.writeString( + 1, + f + ); + } + f = message.getName(); + if (f.length > 0) { + writer.writeString( + 2, + f + ); + } +}; + + +/** + * optional string tag = 1; + * @return {string} + */ +proto.daemon.SaveProfileRequest.Challenge.prototype.getTag = function() { + return /** @type {string} */ (jspb.Message.getFieldWithDefault(this, 1, "")); +}; + + +/** @param {string} value */ +proto.daemon.SaveProfileRequest.Challenge.prototype.setTag = function(value) { + jspb.Message.setProto3StringField(this, 1, value); +}; + + +/** + * optional string name = 2; + * @return {string} + */ +proto.daemon.SaveProfileRequest.Challenge.prototype.getName = function() { + return /** @type {string} */ (jspb.Message.getFieldWithDefault(this, 2, "")); +}; + + +/** @param {string} value */ +proto.daemon.SaveProfileRequest.Challenge.prototype.setName = function(value) { + jspb.Message.setProto3StringField(this, 2, value); +}; + + +/** + * optional string name = 1; + * @return {string} + */ +proto.daemon.SaveProfileRequest.prototype.getName = function() { + return /** @type {string} */ (jspb.Message.getFieldWithDefault(this, 1, "")); +}; + + +/** @param {string} value */ +proto.daemon.SaveProfileRequest.prototype.setName = function(value) { + jspb.Message.setProto3StringField(this, 1, value); +}; + + +/** + * optional bool secret = 2; + * Note that Boolean fields may be set to 0/1 when serialized from a Java server. + * You should avoid comparisons like {@code val === true/false} in those cases. + * @return {boolean} + */ +proto.daemon.SaveProfileRequest.prototype.getSecret = function() { + return /** @type {boolean} */ (jspb.Message.getFieldWithDefault(this, 2, false)); +}; + + +/** @param {boolean} value */ +proto.daemon.SaveProfileRequest.prototype.setSecret = function(value) { + jspb.Message.setProto3BooleanField(this, 2, value); +}; + + +/** + * repeated Challenge challenges = 3; + * @return {!Array} + */ +proto.daemon.SaveProfileRequest.prototype.getChallengesList = function() { + return /** @type{!Array} */ ( + jspb.Message.getRepeatedWrapperField(this, proto.daemon.SaveProfileRequest.Challenge, 3)); +}; + + +/** @param {!Array} value */ +proto.daemon.SaveProfileRequest.prototype.setChallengesList = function(value) { + jspb.Message.setRepeatedWrapperField(this, 3, value); +}; + + +/** + * @param {!proto.daemon.SaveProfileRequest.Challenge=} opt_value + * @param {number=} opt_index + * @return {!proto.daemon.SaveProfileRequest.Challenge} + */ +proto.daemon.SaveProfileRequest.prototype.addChallenges = function(opt_value, opt_index) { + return jspb.Message.addToRepeatedWrapperField(this, 3, opt_value, proto.daemon.SaveProfileRequest.Challenge, opt_index); +}; + + +proto.daemon.SaveProfileRequest.prototype.clearChallengesList = function() { + this.setChallengesList([]); +}; + + + +/** + * Generated by JsPbCodeGenerator. + * @param {Array=} opt_data Optional initial data array, typically from a + * server response, or constructed directly in Javascript. The array is used + * in place and becomes part of the constructed object. It is not cloned. + * If no data is provided, the constructed object will be empty, but still + * valid. + * @extends {jspb.Message} + * @constructor + */ +proto.daemon.DeleteProfileRequest = function(opt_data) { + jspb.Message.initialize(this, opt_data, 0, -1, null, null); +}; +goog.inherits(proto.daemon.DeleteProfileRequest, jspb.Message); +if (goog.DEBUG && !COMPILED) { + proto.daemon.DeleteProfileRequest.displayName = 'proto.daemon.DeleteProfileRequest'; +} + + +if (jspb.Message.GENERATE_TO_OBJECT) { +/** + * Creates an object representation of this proto suitable for use in Soy templates. + * Field names that are reserved in JavaScript and will be renamed to pb_name. + * To access a reserved field use, foo.pb_, eg, foo.pb_default. + * For the list of reserved names please see: + * com.google.apps.jspb.JsClassTemplate.JS_RESERVED_WORDS. + * @param {boolean=} opt_includeInstance Whether to include the JSPB instance + * for transitional soy proto support: http://goto/soy-param-migration + * @return {!Object} + */ +proto.daemon.DeleteProfileRequest.prototype.toObject = function(opt_includeInstance) { + return proto.daemon.DeleteProfileRequest.toObject(opt_includeInstance, this); +}; + + +/** + * Static version of the {@see toObject} method. + * @param {boolean|undefined} includeInstance Whether to include the JSPB + * instance for transitional soy proto support: + * http://goto/soy-param-migration + * @param {!proto.daemon.DeleteProfileRequest} msg The msg instance to transform. + * @return {!Object} + * @suppress {unusedLocalVariables} f is only used for nested messages + */ +proto.daemon.DeleteProfileRequest.toObject = function(includeInstance, msg) { + var f, obj = { + name: jspb.Message.getFieldWithDefault(msg, 1, "") + }; + + if (includeInstance) { + obj.$jspbMessageInstance = msg; + } + return obj; +}; +} + + +/** + * Deserializes binary data (in protobuf wire format). + * @param {jspb.ByteSource} bytes The bytes to deserialize. + * @return {!proto.daemon.DeleteProfileRequest} + */ +proto.daemon.DeleteProfileRequest.deserializeBinary = function(bytes) { + var reader = new jspb.BinaryReader(bytes); + var msg = new proto.daemon.DeleteProfileRequest; + return proto.daemon.DeleteProfileRequest.deserializeBinaryFromReader(msg, reader); +}; + + +/** + * Deserializes binary data (in protobuf wire format) from the + * given reader into the given message object. + * @param {!proto.daemon.DeleteProfileRequest} msg The message object to deserialize into. + * @param {!jspb.BinaryReader} reader The BinaryReader to use. + * @return {!proto.daemon.DeleteProfileRequest} + */ +proto.daemon.DeleteProfileRequest.deserializeBinaryFromReader = function(msg, reader) { + while (reader.nextField()) { + if (reader.isEndGroup()) { + break; + } + var field = reader.getFieldNumber(); + switch (field) { + case 1: + var value = /** @type {string} */ (reader.readString()); + msg.setName(value); + break; + default: + reader.skipField(); + break; + } + } + return msg; +}; + + +/** + * Serializes the message to binary data (in protobuf wire format). + * @return {!Uint8Array} + */ +proto.daemon.DeleteProfileRequest.prototype.serializeBinary = function() { + var writer = new jspb.BinaryWriter(); + proto.daemon.DeleteProfileRequest.serializeBinaryToWriter(this, writer); + return writer.getResultBuffer(); +}; + + +/** + * Serializes the given message to binary data (in protobuf wire + * format), writing to the given BinaryWriter. + * @param {!proto.daemon.DeleteProfileRequest} message + * @param {!jspb.BinaryWriter} writer + * @suppress {unusedLocalVariables} f is only used for nested messages + */ +proto.daemon.DeleteProfileRequest.serializeBinaryToWriter = function(message, writer) { + var f = undefined; + f = message.getName(); + if (f.length > 0) { + writer.writeString( + 1, + f + ); + } +}; + + +/** + * optional string name = 1; + * @return {string} + */ +proto.daemon.DeleteProfileRequest.prototype.getName = function() { + return /** @type {string} */ (jspb.Message.getFieldWithDefault(this, 1, "")); +}; + + +/** @param {string} value */ +proto.daemon.DeleteProfileRequest.prototype.setName = function(value) { + jspb.Message.setProto3StringField(this, 1, value); +}; + + + +/** + * Generated by JsPbCodeGenerator. + * @param {Array=} opt_data Optional initial data array, typically from a + * server response, or constructed directly in Javascript. The array is used + * in place and becomes part of the constructed object. It is not cloned. + * If no data is provided, the constructed object will be empty, but still + * valid. + * @extends {jspb.Message} + * @constructor + */ +proto.daemon.ProfileStatus = function(opt_data) { + jspb.Message.initialize(this, opt_data, 0, -1, null, null); +}; +goog.inherits(proto.daemon.ProfileStatus, jspb.Message); +if (goog.DEBUG && !COMPILED) { + proto.daemon.ProfileStatus.displayName = 'proto.daemon.ProfileStatus'; +} + + +if (jspb.Message.GENERATE_TO_OBJECT) { +/** + * Creates an object representation of this proto suitable for use in Soy templates. + * Field names that are reserved in JavaScript and will be renamed to pb_name. + * To access a reserved field use, foo.pb_, eg, foo.pb_default. + * For the list of reserved names please see: + * com.google.apps.jspb.JsClassTemplate.JS_RESERVED_WORDS. + * @param {boolean=} opt_includeInstance Whether to include the JSPB instance + * for transitional soy proto support: http://goto/soy-param-migration + * @return {!Object} + */ +proto.daemon.ProfileStatus.prototype.toObject = function(opt_includeInstance) { + return proto.daemon.ProfileStatus.toObject(opt_includeInstance, this); +}; + + +/** + * Static version of the {@see toObject} method. + * @param {boolean|undefined} includeInstance Whether to include the JSPB + * instance for transitional soy proto support: + * http://goto/soy-param-migration + * @param {!proto.daemon.ProfileStatus} msg The msg instance to transform. + * @return {!Object} + * @suppress {unusedLocalVariables} f is only used for nested messages + */ +proto.daemon.ProfileStatus.toObject = function(includeInstance, msg) { + var f, obj = { + profile: jspb.Message.getFieldWithDefault(msg, 1, ""), + status: jspb.Message.getFieldWithDefault(msg, 2, "") + }; + + if (includeInstance) { + obj.$jspbMessageInstance = msg; + } + return obj; +}; +} + + +/** + * Deserializes binary data (in protobuf wire format). + * @param {jspb.ByteSource} bytes The bytes to deserialize. + * @return {!proto.daemon.ProfileStatus} + */ +proto.daemon.ProfileStatus.deserializeBinary = function(bytes) { + var reader = new jspb.BinaryReader(bytes); + var msg = new proto.daemon.ProfileStatus; + return proto.daemon.ProfileStatus.deserializeBinaryFromReader(msg, reader); +}; + + +/** + * Deserializes binary data (in protobuf wire format) from the + * given reader into the given message object. + * @param {!proto.daemon.ProfileStatus} msg The message object to deserialize into. + * @param {!jspb.BinaryReader} reader The BinaryReader to use. + * @return {!proto.daemon.ProfileStatus} + */ +proto.daemon.ProfileStatus.deserializeBinaryFromReader = function(msg, reader) { + while (reader.nextField()) { + if (reader.isEndGroup()) { + break; + } + var field = reader.getFieldNumber(); + switch (field) { + case 1: + var value = /** @type {string} */ (reader.readString()); + msg.setProfile(value); + break; + case 2: + var value = /** @type {string} */ (reader.readString()); + msg.setStatus(value); + break; + default: + reader.skipField(); + break; + } + } + return msg; +}; + + +/** + * Serializes the message to binary data (in protobuf wire format). + * @return {!Uint8Array} + */ +proto.daemon.ProfileStatus.prototype.serializeBinary = function() { + var writer = new jspb.BinaryWriter(); + proto.daemon.ProfileStatus.serializeBinaryToWriter(this, writer); + return writer.getResultBuffer(); +}; + + +/** + * Serializes the given message to binary data (in protobuf wire + * format), writing to the given BinaryWriter. + * @param {!proto.daemon.ProfileStatus} message + * @param {!jspb.BinaryWriter} writer + * @suppress {unusedLocalVariables} f is only used for nested messages + */ +proto.daemon.ProfileStatus.serializeBinaryToWriter = function(message, writer) { + var f = undefined; + f = message.getProfile(); + if (f.length > 0) { + writer.writeString( + 1, + f + ); + } + f = message.getStatus(); + if (f.length > 0) { + writer.writeString( + 2, + f + ); + } +}; + + +/** + * optional string profile = 1; + * @return {string} + */ +proto.daemon.ProfileStatus.prototype.getProfile = function() { + return /** @type {string} */ (jspb.Message.getFieldWithDefault(this, 1, "")); +}; + + +/** @param {string} value */ +proto.daemon.ProfileStatus.prototype.setProfile = function(value) { + jspb.Message.setProto3StringField(this, 1, value); +}; + + +/** + * optional string status = 2; + * @return {string} + */ +proto.daemon.ProfileStatus.prototype.getStatus = function() { + return /** @type {string} */ (jspb.Message.getFieldWithDefault(this, 2, "")); +}; + + +/** @param {string} value */ +proto.daemon.ProfileStatus.prototype.setStatus = function(value) { + jspb.Message.setProto3StringField(this, 2, value); +}; + + + /** * Generated by JsPbCodeGenerator. * @param {Array=} opt_data Optional initial data array, typically from a diff --git a/client/src/Pages/Challenges.vue b/client/src/Pages/Challenges.vue index c9cc26f9..b96b0e68 100644 --- a/client/src/Pages/Challenges.vue +++ b/client/src/Pages/Challenges.vue @@ -1,88 +1,949 @@ \ No newline at end of file diff --git a/client/src/Pages/Home.vue b/client/src/Pages/Home.vue index 624d3fb0..58df506a 100644 --- a/client/src/Pages/Home.vue +++ b/client/src/Pages/Home.vue @@ -268,9 +268,9 @@ }); call.on('status', function(status) { that.loaderIsActive = false; - if (status['metadata']['grpc-message'] == "") { + if (!status['metadata']['grpc-message']) { that.success = "Event Successfully Created!" - that.listEvent() + that.listEvent(); }else{ that.error = status['metadata']['grpc-message'] if (status.details === 'token contains an invalid number of segments') { @@ -302,7 +302,7 @@ }); call.on('status', function(status) { that.loaderIsActive = false - if (status['metadata']['grpc-message'] == "") { + if (!status['metadata']['grpc-message']) { that.success = "Action successfully completed!" that.listEvent() }else{ @@ -335,8 +335,8 @@ }); call.on('status', function(status) { that.loaderIsActive = false - if (status['metadata']['grpc-message'] == "") { - that.success = "Event Successfully Stop!" + if (!status['metadata']['grpc-message']) { + that.success = "Event Successfully Stopped!" that.listEvent() }else{ that.error = status['metadata']['grpc-message'] diff --git a/client/src/Pages/Profiles.vue b/client/src/Pages/Profiles.vue new file mode 100644 index 00000000..e3cea7ce --- /dev/null +++ b/client/src/Pages/Profiles.vue @@ -0,0 +1,825 @@ + + + + + \ No newline at end of file diff --git a/client/src/components/ChalModal.vue b/client/src/components/ChalModal.vue index 45b9eb69..8da54181 100644 --- a/client/src/components/ChalModal.vue +++ b/client/src/components/ChalModal.vue @@ -1,5 +1,5 @@