src/com/esotericsoftware/scar/Scar.java
static public String canonical (String path) {
		if (path == null) throw new IllegalArgumentException("path cannot be null.");

		File file = new File(path);
		try {
			return file.getCanonicalPath();
		} catch (IOException ex) {
			file = file.getAbsoluteFile();
			if (file.getName().equals(".")) file = file.getParentFile();
			return file.getPath();
		}
	}
/** Returns the canonical path for the specified path. Eg, if "." is passed, this will resolve the actual path and return
	 * it. */
Returns the canonical path for the specified path. Eg, if "." is passed, this will resolve the actual path and return
it.
Returns the canonical path for the specified path . Eg if " . " is passed this will resolve the actual path and return it .
static public String canonical (String path) {
		if (path == null) throw new IllegalArgumentException("path cannot be null.");
		File file = new File(path);
		try {
			return file.getCanonicalPath();
		} catch (IOException ex) {
			file = file.getAbsoluteFile();
			if (file.getName().equals(".")) file = file.getParentFile();
			return file.getPath();
		}
	}
static public String canonical ( String path ) { if ( path == null ) throw new IllegalArgumentException ( "path cannot be null." ) ; File file = new File ( path ) ; try { return file . getCanonicalPath ( ) ; } catch ( IOException ex ) { file = file . getAbsoluteFile ( ) ; if ( file . getName ( ) . equals ( "." ) ) file = file . getParentFile ( ) ; return file . getPath ( ) ; } }
Returns the canonical path for the specified path.
Returns the canonical path for the specified path .