Исправление не правильного кодирования сообщения
This commit is contained in:
@@ -27,6 +27,8 @@ class Program
|
|||||||
builder.Modules.Add(new BasicExecutionModule());
|
builder.Modules.Add(new BasicExecutionModule());
|
||||||
builder.Modules.Add(new CoCodegenMethodRepository());
|
builder.Modules.Add(new CoCodegenMethodRepository());
|
||||||
builder.UseCollectableContextRepository();
|
builder.UseCollectableContextRepository();
|
||||||
|
builder.Modules.Add(new CancellationRepository());
|
||||||
|
|
||||||
builder.Build();
|
builder.Build();
|
||||||
|
|
||||||
|
|
||||||
|
|||||||
@@ -76,9 +76,20 @@ namespace mROA.Implementation.Frontend
|
|||||||
|
|
||||||
var result = _executeModule.Execute(request, _contextRepository, _representationModule);
|
var result = _executeModule.Execute(request, _contextRepository, _representationModule);
|
||||||
|
|
||||||
var resultType = result is FinalCommandExecution
|
var resultType = MessageType.Unknown;
|
||||||
? MessageType.FinishedCommandExecution
|
|
||||||
: MessageType.ExceptionCommandExecution;
|
switch (result)
|
||||||
|
{
|
||||||
|
case FinalCommandExecution:
|
||||||
|
resultType = MessageType.FinishedCommandExecution;
|
||||||
|
break;
|
||||||
|
case AsyncCommandExecution:
|
||||||
|
resultType = MessageType.AsyncCommandExecution;
|
||||||
|
break;
|
||||||
|
case ExceptionCommandExecution:
|
||||||
|
resultType = MessageType.ExceptionCommandExecution;
|
||||||
|
break;
|
||||||
|
}
|
||||||
|
|
||||||
_representationModule.PostCallMessage(request.Id, resultType, result, result.GetType());
|
_representationModule.PostCallMessage(request.Id, resultType, result, result.GetType());
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -15,6 +15,6 @@ namespace mROA.Implementation
|
|||||||
|
|
||||||
public enum MessageType
|
public enum MessageType
|
||||||
{
|
{
|
||||||
Unknown, FinishedCommandExecution, ExceptionCommandExecution, AsyncCancelCommandExecution, CallRequest, IdAssigning, CancelRequest
|
Unknown, FinishedCommandExecution, ExceptionCommandExecution, AsyncCommandExecution, CallRequest, IdAssigning, CancelRequest
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
Reference in New Issue
Block a user