feat: define full-direction EM planning scope
This commit is contained in:
@@ -20,7 +20,8 @@ public sealed class EmPlanningRequest
|
||||
string outputTrajectoryId,
|
||||
string referencePathId,
|
||||
string previousTrajectoryId,
|
||||
EmMotionModel motionModel)
|
||||
EmMotionModel motionModel,
|
||||
EmPlanningScope planningScope)
|
||||
{
|
||||
ReferencePath = referencePath;
|
||||
Map = map;
|
||||
@@ -35,6 +36,7 @@ public sealed class EmPlanningRequest
|
||||
ReferencePathId = referencePathId;
|
||||
PreviousTrajectoryId = previousTrajectoryId;
|
||||
MotionModel = motionModel;
|
||||
PlanningScope = planningScope;
|
||||
}
|
||||
|
||||
public PathSmoothingResult ReferencePath { get; }
|
||||
@@ -50,6 +52,7 @@ public sealed class EmPlanningRequest
|
||||
public string ReferencePathId { get; }
|
||||
public string PreviousTrajectoryId { get; }
|
||||
public EmMotionModel MotionModel { get; }
|
||||
public EmPlanningScope PlanningScope { get; }
|
||||
}
|
||||
|
||||
// The request owns this DTO contract; Task 2 adds its request-bound settings.
|
||||
|
||||
@@ -0,0 +1,7 @@
|
||||
namespace MultiWheelC.TrajectoryPlanning.EMPlanner;
|
||||
|
||||
public enum EmPlanningScope
|
||||
{
|
||||
RollingHorizon,
|
||||
FullDirectionSegment,
|
||||
}
|
||||
@@ -19,5 +19,8 @@ public enum EmPlanningStatus
|
||||
Cancelled,
|
||||
ValidationFailed,
|
||||
Superseded,
|
||||
NoProgress,
|
||||
TerminalPoseMismatch,
|
||||
FullSegmentResourceLimitExceeded,
|
||||
Failed,
|
||||
}
|
||||
|
||||
@@ -16,7 +16,8 @@ public sealed class EmTrajectoryMetadata
|
||||
int segmentIndex,
|
||||
TravelDirection direction,
|
||||
EmTerminalType terminalType,
|
||||
EmLongitudinalMode longitudinalMode)
|
||||
EmLongitudinalMode longitudinalMode,
|
||||
EmPlanningScope planningScope)
|
||||
{
|
||||
if (string.IsNullOrWhiteSpace(trajectoryId))
|
||||
throw new ArgumentException("A trajectory ID is required.", nameof(trajectoryId));
|
||||
@@ -34,6 +35,8 @@ public sealed class EmTrajectoryMetadata
|
||||
throw new ArgumentOutOfRangeException(nameof(terminalType));
|
||||
if (!Enum.IsDefined(typeof(EmLongitudinalMode), longitudinalMode))
|
||||
throw new ArgumentOutOfRangeException(nameof(longitudinalMode));
|
||||
if (!Enum.IsDefined(typeof(EmPlanningScope), planningScope))
|
||||
throw new ArgumentOutOfRangeException(nameof(planningScope));
|
||||
|
||||
TrajectoryId = trajectoryId;
|
||||
GeneratedAtUtc = generatedAtUtc;
|
||||
@@ -46,6 +49,7 @@ public sealed class EmTrajectoryMetadata
|
||||
Direction = direction;
|
||||
TerminalType = terminalType;
|
||||
LongitudinalMode = longitudinalMode;
|
||||
PlanningScope = planningScope;
|
||||
}
|
||||
|
||||
public string TrajectoryId { get; }
|
||||
@@ -59,4 +63,5 @@ public sealed class EmTrajectoryMetadata
|
||||
public TravelDirection Direction { get; }
|
||||
public EmTerminalType TerminalType { get; }
|
||||
public EmLongitudinalMode LongitudinalMode { get; }
|
||||
public EmPlanningScope PlanningScope { get; }
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user