InitializeForPath() public method

public InitializeForPath ( Path p ) : void
p Path
return void
示例#1
0
        /** Prepares low level path variables for calculation.
         * Called before a path search will take place.
         * Always called before the Prepare, Initialize and CalculateStep functions
         */
        protected void PrepareBase(PathHandler pathHandler)
        {
            //Path IDs have overflowed 65K, cleanup is needed
            //Since pathIDs are handed out sequentially, we can do this
            if (pathHandler.PathID > pathID)
            {
                pathHandler.ClearPathIDs();
            }

            //Make sure the path has a reference to the pathHandler
            this.pathHandler = pathHandler;
            //Assign relevant path data to the pathHandler
            pathHandler.InitializeForPath(this);

            // Make sure that internalTagPenalties is an array which has the length 32
            if (internalTagPenalties == null || internalTagPenalties.Length != 32)
            {
                internalTagPenalties = ZeroTagPenalties;
            }

            try {
                ErrorCheck();
            } catch (System.Exception e) {
                ForceLogError("Exception in path " + pathID + "\n" + e);
            }
        }
示例#2
0
 // Token: 0x06000265 RID: 613 RVA: 0x00014624 File Offset: 0x00012A24
 public void PrepareBase(PathHandler pathHandler)
 {
     if (pathHandler.PathID > this.pathID)
     {
         pathHandler.ClearPathIDs();
     }
     this.pathHandler = pathHandler;
     pathHandler.InitializeForPath(this);
     if (this.internalTagPenalties == null || this.internalTagPenalties.Length != 32)
     {
         this.internalTagPenalties = Path.ZeroTagPenalties;
     }
     try
     {
         this.ErrorCheck();
     }
     catch (Exception ex)
     {
         this.ForceLogError(string.Concat(new object[]
         {
             "Exception in path ",
             this.pathID,
             "\n",
             ex.ToString()
         }));
     }
 }
示例#3
0
        /** Prepares low level path variables for calculation.
         * Called before a path search will take place.
         * Always called before the Prepare, Initialize and CalculateStep functions
         */
        public void PrepareBase(PathHandler pathHandler)
        {
            //Path IDs have overflowed 65K, cleanup is needed
            //Since pathIDs are handed out sequentially, we can do this
            if (pathHandler.PathID > pathID)
            {
                pathHandler.ClearPathIDs();
            }

            //Make sure the path has a reference to the pathHandler
            this.pathHandler = pathHandler;
            //Assign relevant path data to the pathHandler
            pathHandler.InitializeForPath(this);

            try {
                ErrorCheck();
            } catch (System.Exception e) {
                ForceLogError("Exception in path " + pathID + "\n" + e.ToString());
            }
        }
 // Token: 0x060023B0 RID: 9136 RVA: 0x001957A0 File Offset: 0x001939A0
 protected void PrepareBase(PathHandler pathHandler)
 {
     if (pathHandler.PathID > this.pathID)
     {
         pathHandler.ClearPathIDs();
     }
     this.pathHandler = pathHandler;
     pathHandler.InitializeForPath(this);
     if (this.internalTagPenalties == null || this.internalTagPenalties.Length != 32)
     {
         this.internalTagPenalties = Path.ZeroTagPenalties;
     }
     try
     {
         this.ErrorCheck();
     }
     catch (Exception ex)
     {
         this.FailWithError(ex.Message);
     }
 }
示例#5
0
		/** Prepares low level path variables for calculation.
		  * Called before a path search will take place.
		  * Always called before the Prepare, Initialize and CalculateStep functions
		  */
		public void PrepareBase (PathHandler pathHandler) {

			//Path IDs have overflowed 65K, cleanup is needed
			//Since pathIDs are handed out sequentially, we can do this
			if (pathHandler.PathID > pathID) {
				pathHandler.ClearPathIDs ();
			}

			//Make sure the path has a reference to the pathHandler
			this.pathHandler = pathHandler;
			//Assign relevant path data to the pathHandler
			pathHandler.InitializeForPath (this);

			// Make sure that internalTagPenalties is an array which has the length 32
			if (internalTagPenalties == null || internalTagPenalties.Length != 32)
				internalTagPenalties = ZeroTagPenalties;

			try {
				ErrorCheck ();
			} catch (System.Exception e) {
				ForceLogError ("Exception in path "+pathID+"\n"+e);
			}
		}
示例#6
0
 public void PrepareBase(PathHandler pathHandler)
 {
     if (pathHandler.PathID > this.pathID)
     {
         pathHandler.ClearPathIDs();
     }
     this.pathHandler = pathHandler;
     pathHandler.InitializeForPath(this);
     if (this.internalTagPenalties == null || this.internalTagPenalties.Length != 32)
     {
         this.internalTagPenalties = Path.ZeroTagPenalties;
     }
     try
     {
         this.ErrorCheck();
     }
     catch (Exception ex)
     {
         this.ForceLogError(string.Concat(new object[]
         {
             "Exception in path ",
             this.pathID,
             "\n",
             ex
         }));
     }
 }
示例#7
0
		/** Prepares low level path variables for calculation.
		  * Called before a path search will take place.
		  * Always called before the Prepare, Initialize and CalculateStep functions
		  */
		public void PrepareBase (PathHandler pathHandler) {
			
			//Path IDs have overflowed 65K, cleanup is needed
			//Since pathIDs are handed out sequentially, we can do this
			if (pathHandler.PathID > pathID) {
				pathHandler.ClearPathIDs ();
			}
			
			//Make sure the path has a reference to the pathHandler
			this.pathHandler = pathHandler;
			//Assign relevant path data to the pathHandler
			pathHandler.InitializeForPath (this);

			try {
				ErrorCheck ();
			} catch (System.Exception e) {
				ForceLogError ("Exception in path "+pathID+"\n"+e.ToString());
			}
		}