コード例 #1
0
 internal OutgoingRequest(long targetEntityId, long senderEntityId,
                          global::Generated.Improbable.Gdk.Tests.BlittableTypes.SecondCommandRequest request)
 {
     this.TargetEntityId = targetEntityId;
     this.SenderEntityId = senderEntityId;
     this.RawRequest     = request;
 }
コード例 #2
0
        public static void SendSecondCommandRequest(this CommandRequestSender <SpatialOSBlittableComponent> commandRequestSender,
                                                    long targetEntityId, global::Generated.Improbable.Gdk.Tests.BlittableTypes.SecondCommandRequest request)
        {
            var translation = BlittableComponent.Translation.GetTranslation(commandRequestSender.InternalHandleToTranslation);

            translation.SecondCommandRequests.Add(new BlittableComponent.SecondCommand.OutgoingRequest(targetEntityId,
                                                                                                       commandRequestSender.EntityId, request));
        }
コード例 #3
0
 public ReceivedRequest(long requestId,
                        string callerWorkerId,
                        List <string> callerAttributeSet,
                        global::Generated.Improbable.Gdk.Tests.BlittableTypes.SecondCommandRequest request)
 {
     RequestId          = requestId;
     CallerWorkerId     = callerWorkerId;
     CallerAttributeSet = callerAttributeSet;
     Payload            = request;
 }
コード例 #4
0
 public Request(EntityId targetEntityId,
                global::Generated.Improbable.Gdk.Tests.BlittableTypes.SecondCommandRequest request,
                uint?timeoutMillis        = null,
                bool allowShortCircuiting = false)
 {
     TargetEntityId       = targetEntityId;
     Payload              = request;
     TimeoutMillis        = timeoutMillis;
     AllowShortCircuiting = allowShortCircuiting;
 }
コード例 #5
0
 internal Response(long entityId,
                   string message,
                   CommandStatusCode statusCode,
                   global::Generated.Improbable.Gdk.Tests.BlittableTypes.SecondCommandResponse?response,
                   global::Generated.Improbable.Gdk.Tests.BlittableTypes.SecondCommandRequest request)
 {
     this.EntityId    = entityId;
     this.Message     = message;
     this.StatusCode  = statusCode;
     this.RawResponse = response;
     this.RawRequest  = request;
 }
コード例 #6
0
 internal Request(uint requestId,
                  Translation translation,
                  string callerWorkerId,
                  List <string> callerAttributeSet,
                  global::Generated.Improbable.Gdk.Tests.BlittableTypes.SecondCommandRequest request)
 {
     this.RequestId          = requestId;
     this.Translation        = translation;
     this.CallerWorkerId     = callerWorkerId;
     this.CallerAttributeSet = callerAttributeSet;
     this.RawRequest         = request;
 }
コード例 #7
0
 public ReceivedResponse(EntityId entityId,
                         string message,
                         StatusCode statusCode,
                         global::Generated.Improbable.Gdk.Tests.BlittableTypes.SecondCommandResponse?response,
                         global::Generated.Improbable.Gdk.Tests.BlittableTypes.SecondCommandRequest request)
 {
     EntityId        = entityId;
     Message         = message;
     StatusCode      = statusCode;
     ResponsePayload = response;
     RequestPayload  = request;
 }
コード例 #8
0
 public ReceivedResponse(EntityId entityId,
                         string message,
                         StatusCode statusCode,
                         global::Generated.Improbable.Gdk.Tests.BlittableTypes.SecondCommandResponse?response,
                         global::Generated.Improbable.Gdk.Tests.BlittableTypes.SecondCommandRequest request,
                         System.Object context,
                         long requestId)
 {
     EntityId        = entityId;
     Message         = message;
     StatusCode      = statusCode;
     ResponsePayload = response;
     RequestPayload  = request;
     Context         = context;
     RequestId       = requestId;
 }
コード例 #9
0
 public static Request CreateRequest(EntityId targetEntityId,
                                     global::Generated.Improbable.Gdk.Tests.BlittableTypes.SecondCommandRequest request,
                                     uint?timeoutMillis        = null,
                                     bool allowShortCircuiting = false,
                                     System.Object context     = null)
 {
     return(new Request
     {
         TargetEntityId = targetEntityId,
         Payload = request,
         TimeoutMillis = timeoutMillis,
         AllowShortCircuiting = allowShortCircuiting,
         Context = context,
         RequestId = global::Improbable.Gdk.Core.CommandRequestIdGenerator.GetNext(),
     });
 }
コード例 #10
0
        public static global::Improbable.Gdk.Tests.BlittableTypes.SecondCommandRequest ToSpatial(global::Generated.Improbable.Gdk.Tests.BlittableTypes.SecondCommandRequest nativeType)
        {
            var spatialType = new global::Improbable.Gdk.Tests.BlittableTypes.SecondCommandRequest();

            spatialType.field = nativeType.Field;
            return(spatialType);
        }
コード例 #11
0
                public void SendSecondCommandRequest(EntityId entityId, global::Generated.Improbable.Gdk.Tests.BlittableTypes.SecondCommandRequest request)
                {
                    var ecsCommandRequestSender = entityManager.GetComponentData <CommandSenders.SecondCommand>(entity);

                    ecsCommandRequestSender.RequestsToSend.Add(SecondCommand.CreateRequest(entityId, request));
                }