Code example for Path

Methods: isAbsolute

    this.platform = platform;
    this.console = console;
    // Ideally we would do isRealPath() to make sure canonicalRootPath doesn't contain symlinks, but 
    // since this requires IO it's the responsibility of the caller. Checking isAbsolute() is the 
    // next best thing. 
    // The root repo has no explicit name. All other repos will get a global, unique name. 
    this.canonicalPathNames.put(canonicalRootPath, Optional.<String>absent());
   * The table of canonical names grows as more repos are discovered. This returns a copy of the 
   * current table. 
  public ImmutableMap<Path, Optional<String>> getCanonicalPathNames() {
    return ImmutableMap.copyOf(canonicalPathNames);
  public Repository getRepositoryByCanonicalName(Optional<String> canonicalName)
      throws IOException, InterruptedException {