示例#1
0
 /** Restart the pathfinder by creating a new instance and starting this one. */
 public static synchronized void restartPathfinder() {
   if (instance != null) {
     instance.saveShutdown();
     StoppableStorage.getInstance().remove(instance);
   }
   instance = new Pathfinder();
   instance.setUncaughtExceptionHandler(PathfinderCrashHandler.getInstance());
 }
示例#2
0
 /**
  * Get instance of singleton.
  *
  * @return The instance of the pathfinder class.
  */
 public static synchronized Pathfinder getInstance() {
   if (instance == null) {
     instance = new Pathfinder();
     instance.setUncaughtExceptionHandler(PathfinderCrashHandler.getInstance());
   }
   return instance;
 }