예제 #1
0
 public void MergeFrom(DpPolyPathConfig other)
 {
     if (other == null)
     {
         return;
     }
     if (other.waypointSamplerConfig_ != null)
     {
         if (waypointSamplerConfig_ == null)
         {
             waypointSamplerConfig_ = new global::Apollo.Planning.WaypointSamplerConfig();
         }
         WaypointSamplerConfig.MergeFrom(other.WaypointSamplerConfig);
     }
     if (other.EvalTimeInterval != 0D)
     {
         EvalTimeInterval = other.EvalTimeInterval;
     }
     if (other.PathResolution != 0D)
     {
         PathResolution = other.PathResolution;
     }
     if (other.ObstacleIgnoreDistance != 0D)
     {
         ObstacleIgnoreDistance = other.ObstacleIgnoreDistance;
     }
     if (other.ObstacleCollisionDistance != 0D)
     {
         ObstacleCollisionDistance = other.ObstacleCollisionDistance;
     }
     if (other.ObstacleRiskDistance != 0D)
     {
         ObstacleRiskDistance = other.ObstacleRiskDistance;
     }
     if (other.ObstacleCollisionCost != 0D)
     {
         ObstacleCollisionCost = other.ObstacleCollisionCost;
     }
     if (other.PathLCost != 0D)
     {
         PathLCost = other.PathLCost;
     }
     if (other.PathDlCost != 0D)
     {
         PathDlCost = other.PathDlCost;
     }
     if (other.PathDdlCost != 0D)
     {
         PathDdlCost = other.PathDdlCost;
     }
     if (other.PathLCostParamL0 != 0D)
     {
         PathLCostParamL0 = other.PathLCostParamL0;
     }
     if (other.PathLCostParamB != 0D)
     {
         PathLCostParamB = other.PathLCostParamB;
     }
     if (other.PathLCostParamK != 0D)
     {
         PathLCostParamK = other.PathLCostParamK;
     }
     if (other.PathOutLaneCost != 0D)
     {
         PathOutLaneCost = other.PathOutLaneCost;
     }
     if (other.PathEndLCost != 0D)
     {
         PathEndLCost = other.PathEndLCost;
     }
 }
예제 #2
0
        public override int GetHashCode()
        {
            int hash = 1;

            if (waypointSamplerConfig_ != null)
            {
                hash ^= WaypointSamplerConfig.GetHashCode();
            }
            if (EvalTimeInterval != 0D)
            {
                hash ^= EvalTimeInterval.GetHashCode();
            }
            if (PathResolution != 0D)
            {
                hash ^= PathResolution.GetHashCode();
            }
            if (ObstacleIgnoreDistance != 0D)
            {
                hash ^= ObstacleIgnoreDistance.GetHashCode();
            }
            if (ObstacleCollisionDistance != 0D)
            {
                hash ^= ObstacleCollisionDistance.GetHashCode();
            }
            if (ObstacleRiskDistance != 0D)
            {
                hash ^= ObstacleRiskDistance.GetHashCode();
            }
            if (ObstacleCollisionCost != 0D)
            {
                hash ^= ObstacleCollisionCost.GetHashCode();
            }
            if (PathLCost != 0D)
            {
                hash ^= PathLCost.GetHashCode();
            }
            if (PathDlCost != 0D)
            {
                hash ^= PathDlCost.GetHashCode();
            }
            if (PathDdlCost != 0D)
            {
                hash ^= PathDdlCost.GetHashCode();
            }
            if (PathLCostParamL0 != 0D)
            {
                hash ^= PathLCostParamL0.GetHashCode();
            }
            if (PathLCostParamB != 0D)
            {
                hash ^= PathLCostParamB.GetHashCode();
            }
            if (PathLCostParamK != 0D)
            {
                hash ^= PathLCostParamK.GetHashCode();
            }
            if (PathOutLaneCost != 0D)
            {
                hash ^= PathOutLaneCost.GetHashCode();
            }
            if (PathEndLCost != 0D)
            {
                hash ^= PathEndLCost.GetHashCode();
            }
            return(hash);
        }