Java Canonical Path Create getCanonicalPath(String path)

Here you can find the source of getCanonicalPath(String path)

Description

get Canonical Path

License

Open Source License

Declaration

public static String getCanonicalPath(String path) 

Method Source Code


//package com.java2s;
//License from project: Open Source License 

import java.io.*;

public class Main {

    public static String getCanonicalPath(String path) {
        String result = null;//from ww  w.j a  v  a2  s . com
        try {
            result = new File(path).getCanonicalPath();
        } catch (IOException e) {
            throw new RuntimeException("get Canonical path exception", e);
        }
        return result;
    }
}

Related

  1. getCanonicalPath(String filePath, String prefix)
  2. getCanonicalPath(String inPath)
  3. getCanonicalPath(String name)
  4. getCanonicalPath(String outputPath)
  5. getCanonicalPath(String path)
  6. getCanonicalPath(String path)
  7. getCanonicalPath(String path)
  8. getCanonicalPath(String path)
  9. getCanonicalPath(String path)