Skip to content

Commit

Permalink
renaming
Browse files Browse the repository at this point in the history
  • Loading branch information
Scretch9 committed Jan 9, 2024
1 parent 3329c63 commit 6d4dba7
Show file tree
Hide file tree
Showing 10 changed files with 2,174 additions and 58 deletions.
2 changes: 1 addition & 1 deletion src/Point/IPoint.cs
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ public interface IPoint {

void EnableTimeoutLeft(bool enableMovementFailed);
void EnableTimeoutRight(bool enableMovementFailed);
void EnableInitializationTimeout(bool enableInitializationFailed);
void EnableInitializationTimeout(bool enableInitializationTimeout);
void PreventLeftEndPosition(PreventedPositionMessage request);
void PreventRightEndPosition(PreventedPositionMessage request);
Task PutIntoUnintendedPosition(DegradedPositionMessage request);
Expand Down
4 changes: 2 additions & 2 deletions src/Point/Services/PointService.cs
Original file line number Diff line number Diff line change
Expand Up @@ -53,9 +53,9 @@ public override async Task<Empty> OverrideSciMessage(SciMessage request, ServerC
return new Empty();
}

public override Task<Empty> ScheduleInitializationFailed(EnableInitializationFailedMessage request, ServerCallContext context)
public override Task<Empty> ScheduleInitializationTimeout(EnableInitializationTimeoutMessage request, ServerCallContext context)
{
_point.EnableInitializationTimeout(request.EnableInitializationFailed);
_point.EnableInitializationTimeout(request.EnableInitializationTimeout);
return Task.FromResult(new Empty());
}

Expand Down
4 changes: 2 additions & 2 deletions src/Point/rasta-point-web/src/Point.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ import { PointClient } from './proto/PointServiceClientPb';

import {
PreventedPosition, AbilityToMoveMessage, AbilityToMove, PreventedPositionMessage, DegradedPositionMessage, EnableMovementFailedMessage,
EnableInitializationFailedMessage,
EnableInitializationTimeoutMessage,
} from './proto/point_pb';
import { PointState, SimulatedPointState, SimulatorConfiguration } from './App';

Expand Down Expand Up @@ -374,7 +374,7 @@ function Point({
label="Enable Initialization Timeout"
active={simulatedPointState?.simulateInitializationTimeout || false}
onChange={
(enable) => sendCommand((client) => client.scheduleInitializationFailed(new EnableInitializationFailedMessage().setEnableinitializationfailed(enable), null))
(enable) => sendCommand((client) => client.scheduleInitializationTimeout(new EnableInitializationTimeoutMessage().setEnableinitializationtimeout(enable), null))
}
/>
</div>
Expand Down
28 changes: 14 additions & 14 deletions src/Point/rasta-point-web/src/proto/PointServiceClientPb.ts
Original file line number Diff line number Diff line change
Expand Up @@ -513,47 +513,47 @@ export class PointClient {
this.methodDescriptorScheduleTimeoutLeft);
}

methodDescriptorScheduleInitializationFailed = new grpcWeb.MethodDescriptor(
'/point.Point/ScheduleInitializationFailed',
methodDescriptorScheduleInitializationTimeout = new grpcWeb.MethodDescriptor(
'/point.Point/ScheduleInitializationTimeout',
grpcWeb.MethodType.UNARY,
point_pb.EnableInitializationFailedMessage,
point_pb.EnableInitializationTimeoutMessage,
google_protobuf_empty_pb.Empty,
(request: point_pb.EnableInitializationFailedMessage) => {
(request: point_pb.EnableInitializationTimeoutMessage) => {
return request.serializeBinary();
},
google_protobuf_empty_pb.Empty.deserializeBinary
);

scheduleInitializationFailed(
request: point_pb.EnableInitializationFailedMessage,
scheduleInitializationTimeout(
request: point_pb.EnableInitializationTimeoutMessage,
metadata: grpcWeb.Metadata | null): Promise<google_protobuf_empty_pb.Empty>;

scheduleInitializationFailed(
request: point_pb.EnableInitializationFailedMessage,
scheduleInitializationTimeout(
request: point_pb.EnableInitializationTimeoutMessage,
metadata: grpcWeb.Metadata | null,
callback: (err: grpcWeb.RpcError,
response: google_protobuf_empty_pb.Empty) => void): grpcWeb.ClientReadableStream<google_protobuf_empty_pb.Empty>;

scheduleInitializationFailed(
request: point_pb.EnableInitializationFailedMessage,
scheduleInitializationTimeout(
request: point_pb.EnableInitializationTimeoutMessage,
metadata: grpcWeb.Metadata | null,
callback?: (err: grpcWeb.RpcError,
response: google_protobuf_empty_pb.Empty) => void) {
if (callback !== undefined) {
return this.client_.rpcCall(
this.hostname_ +
'/point.Point/ScheduleInitializationFailed',
'/point.Point/ScheduleInitializationTimeout',
request,
metadata || {},
this.methodDescriptorScheduleInitializationFailed,
this.methodDescriptorScheduleInitializationTimeout,
callback);
}
return this.client_.unaryCall(
this.hostname_ +
'/point.Point/ScheduleInitializationFailed',
'/point.Point/ScheduleInitializationTimeout',
request,
metadata || {},
this.methodDescriptorScheduleInitializationFailed);
this.methodDescriptorScheduleInitializationTimeout);
}

methodDescriptorReset = new grpcWeb.MethodDescriptor(
Expand Down
20 changes: 10 additions & 10 deletions src/Point/rasta-point-web/src/proto/point_pb.d.ts
Original file line number Diff line number Diff line change
Expand Up @@ -99,21 +99,21 @@ export namespace EnableMovementFailedMessage {
}
}

export class EnableInitializationFailedMessage extends jspb.Message {
getEnableinitializationfailed(): boolean;
setEnableinitializationfailed(value: boolean): EnableInitializationFailedMessage;
export class EnableInitializationTimeoutMessage extends jspb.Message {
getEnableinitializationtimeout(): boolean;
setEnableinitializationtimeout(value: boolean): EnableInitializationTimeoutMessage;

serializeBinary(): Uint8Array;
toObject(includeInstance?: boolean): EnableInitializationFailedMessage.AsObject;
static toObject(includeInstance: boolean, msg: EnableInitializationFailedMessage): EnableInitializationFailedMessage.AsObject;
static serializeBinaryToWriter(message: EnableInitializationFailedMessage, writer: jspb.BinaryWriter): void;
static deserializeBinary(bytes: Uint8Array): EnableInitializationFailedMessage;
static deserializeBinaryFromReader(message: EnableInitializationFailedMessage, reader: jspb.BinaryReader): EnableInitializationFailedMessage;
toObject(includeInstance?: boolean): EnableInitializationTimeoutMessage.AsObject;
static toObject(includeInstance: boolean, msg: EnableInitializationTimeoutMessage): EnableInitializationTimeoutMessage.AsObject;
static serializeBinaryToWriter(message: EnableInitializationTimeoutMessage, writer: jspb.BinaryWriter): void;
static deserializeBinary(bytes: Uint8Array): EnableInitializationTimeoutMessage;
static deserializeBinaryFromReader(message: EnableInitializationTimeoutMessage, reader: jspb.BinaryReader): EnableInitializationTimeoutMessage;
}

export namespace EnableInitializationFailedMessage {
export namespace EnableInitializationTimeoutMessage {
export type AsObject = {
enableinitializationfailed: boolean,
enableinitializationtimeout: boolean,
}
}

Expand Down
52 changes: 26 additions & 26 deletions src/Point/rasta-point-web/src/proto/point_pb.js
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@ goog.object.extend(proto, google_protobuf_empty_pb);
goog.exportSymbol('proto.point.AbilityToMove', null, global);
goog.exportSymbol('proto.point.AbilityToMoveMessage', null, global);
goog.exportSymbol('proto.point.DegradedPositionMessage', null, global);
goog.exportSymbol('proto.point.EnableInitializationFailedMessage', null, global);
goog.exportSymbol('proto.point.EnableInitializationTimeoutMessage', null, global);
goog.exportSymbol('proto.point.EnableMovementFailedMessage', null, global);
goog.exportSymbol('proto.point.PointDegradedPosition', null, global);
goog.exportSymbol('proto.point.PointDegradedPositionMessage', null, global);
Expand Down Expand Up @@ -150,16 +150,16 @@ if (goog.DEBUG && !COMPILED) {
* @extends {jspb.Message}
* @constructor
*/
proto.point.EnableInitializationFailedMessage = function(opt_data) {
proto.point.EnableInitializationTimeoutMessage = function(opt_data) {
jspb.Message.initialize(this, opt_data, 0, -1, null, null);
};
goog.inherits(proto.point.EnableInitializationFailedMessage, jspb.Message);
goog.inherits(proto.point.EnableInitializationTimeoutMessage, jspb.Message);
if (goog.DEBUG && !COMPILED) {
/**
* @public
* @override
*/
proto.point.EnableInitializationFailedMessage.displayName = 'proto.point.EnableInitializationFailedMessage';
proto.point.EnableInitializationTimeoutMessage.displayName = 'proto.point.EnableInitializationTimeoutMessage';
}
/**
* Generated by JsPbCodeGenerator.
Expand Down Expand Up @@ -923,8 +923,8 @@ if (jspb.Message.GENERATE_TO_OBJECT) {
* http://goto/soy-param-migration
* @return {!Object}
*/
proto.point.EnableInitializationFailedMessage.prototype.toObject = function(opt_includeInstance) {
return proto.point.EnableInitializationFailedMessage.toObject(opt_includeInstance, this);
proto.point.EnableInitializationTimeoutMessage.prototype.toObject = function(opt_includeInstance) {
return proto.point.EnableInitializationTimeoutMessage.toObject(opt_includeInstance, this);
};


Expand All @@ -933,13 +933,13 @@ proto.point.EnableInitializationFailedMessage.prototype.toObject = function(opt_
* @param {boolean|undefined} includeInstance Deprecated. Whether to include
* the JSPB instance for transitional soy proto support:
* http://goto/soy-param-migration
* @param {!proto.point.EnableInitializationFailedMessage} msg The msg instance to transform.
* @param {!proto.point.EnableInitializationTimeoutMessage} msg The msg instance to transform.
* @return {!Object}
* @suppress {unusedLocalVariables} f is only used for nested messages
*/
proto.point.EnableInitializationFailedMessage.toObject = function(includeInstance, msg) {
proto.point.EnableInitializationTimeoutMessage.toObject = function(includeInstance, msg) {
var f, obj = {
enableinitializationfailed: jspb.Message.getBooleanFieldWithDefault(msg, 1, false)
enableinitializationtimeout: jspb.Message.getBooleanFieldWithDefault(msg, 1, false)
};

if (includeInstance) {
Expand All @@ -953,23 +953,23 @@ proto.point.EnableInitializationFailedMessage.toObject = function(includeInstanc
/**
* Deserializes binary data (in protobuf wire format).
* @param {jspb.ByteSource} bytes The bytes to deserialize.
* @return {!proto.point.EnableInitializationFailedMessage}
* @return {!proto.point.EnableInitializationTimeoutMessage}
*/
proto.point.EnableInitializationFailedMessage.deserializeBinary = function(bytes) {
proto.point.EnableInitializationTimeoutMessage.deserializeBinary = function(bytes) {
var reader = new jspb.BinaryReader(bytes);
var msg = new proto.point.EnableInitializationFailedMessage;
return proto.point.EnableInitializationFailedMessage.deserializeBinaryFromReader(msg, reader);
var msg = new proto.point.EnableInitializationTimeoutMessage;
return proto.point.EnableInitializationTimeoutMessage.deserializeBinaryFromReader(msg, reader);
};


/**
* Deserializes binary data (in protobuf wire format) from the
* given reader into the given message object.
* @param {!proto.point.EnableInitializationFailedMessage} msg The message object to deserialize into.
* @param {!proto.point.EnableInitializationTimeoutMessage} msg The message object to deserialize into.
* @param {!jspb.BinaryReader} reader The BinaryReader to use.
* @return {!proto.point.EnableInitializationFailedMessage}
* @return {!proto.point.EnableInitializationTimeoutMessage}
*/
proto.point.EnableInitializationFailedMessage.deserializeBinaryFromReader = function(msg, reader) {
proto.point.EnableInitializationTimeoutMessage.deserializeBinaryFromReader = function(msg, reader) {
while (reader.nextField()) {
if (reader.isEndGroup()) {
break;
Expand All @@ -978,7 +978,7 @@ proto.point.EnableInitializationFailedMessage.deserializeBinaryFromReader = func
switch (field) {
case 1:
var value = /** @type {boolean} */ (reader.readBool());
msg.setEnableinitializationfailed(value);
msg.setEnableinitializationtimeout(value);
break;
default:
reader.skipField();
Expand All @@ -993,23 +993,23 @@ proto.point.EnableInitializationFailedMessage.deserializeBinaryFromReader = func
* Serializes the message to binary data (in protobuf wire format).
* @return {!Uint8Array}
*/
proto.point.EnableInitializationFailedMessage.prototype.serializeBinary = function() {
proto.point.EnableInitializationTimeoutMessage.prototype.serializeBinary = function() {
var writer = new jspb.BinaryWriter();
proto.point.EnableInitializationFailedMessage.serializeBinaryToWriter(this, writer);
proto.point.EnableInitializationTimeoutMessage.serializeBinaryToWriter(this, writer);
return writer.getResultBuffer();
};


/**
* Serializes the given message to binary data (in protobuf wire
* format), writing to the given BinaryWriter.
* @param {!proto.point.EnableInitializationFailedMessage} message
* @param {!proto.point.EnableInitializationTimeoutMessage} message
* @param {!jspb.BinaryWriter} writer
* @suppress {unusedLocalVariables} f is only used for nested messages
*/
proto.point.EnableInitializationFailedMessage.serializeBinaryToWriter = function(message, writer) {
proto.point.EnableInitializationTimeoutMessage.serializeBinaryToWriter = function(message, writer) {
var f = undefined;
f = message.getEnableinitializationfailed();
f = message.getEnableinitializationtimeout();
if (f) {
writer.writeBool(
1,
Expand All @@ -1020,19 +1020,19 @@ proto.point.EnableInitializationFailedMessage.serializeBinaryToWriter = function


/**
* optional bool EnableInitializationFailed = 1;
* optional bool EnableInitializationTimeout = 1;
* @return {boolean}
*/
proto.point.EnableInitializationFailedMessage.prototype.getEnableinitializationfailed = function() {
proto.point.EnableInitializationTimeoutMessage.prototype.getEnableinitializationtimeout = function() {
return /** @type {boolean} */ (jspb.Message.getBooleanFieldWithDefault(this, 1, false));
};


/**
* @param {boolean} value
* @return {!proto.point.EnableInitializationFailedMessage} returns this
* @return {!proto.point.EnableInitializationTimeoutMessage} returns this
*/
proto.point.EnableInitializationFailedMessage.prototype.setEnableinitializationfailed = function(value) {
proto.point.EnableInitializationTimeoutMessage.prototype.setEnableinitializationtimeout = function(value) {
return jspb.Message.setProto3BooleanField(this, 1, value);
};

Expand Down
Loading

0 comments on commit 6d4dba7

Please sign in to comment.