Package worldBuilder

Class Journey


  • public class Journey
    extends java.lang.Object
    These nodes are used to define territory and trade routes. - A border is the line, between two cities, where the cost of travel (from each) is equal. - A trade route is the lowest cost path between them. We identify these by expanding journeys out from each city until they meet journeys from another city.
    • Nested Class Summary

      Nested Classes 
      Modifier and Type Class Description
      class  Journey.NextSteps
      this is a (lowest) cost-ordered queue of possible next steps in our outward journeys.
    • Constructor Summary

      Constructors 
      Constructor Description
      Journey​(int index, int fromCity, Journey fromPoint)
      create a node for the next step in an outward journey
    • Method Summary

      • Methods inherited from class java.lang.Object

        equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
    • Field Detail

      • index

        public int index
      • city

        public int city
      • cost

        public double cost
    • Constructor Detail

      • Journey

        public Journey​(int index,
                       int fromCity,
                       Journey fromPoint)
        create a node for the next step in an outward journey
        Parameters:
        index - ... corresponding MeshPoint index
        fromCity - ... large city from which we are traveling
        fromPoint - ... previous point in our journey