public static String toSystemIndependentPath(String path){
  if (File.separatorChar != '/') {
    path=path.replace(File.separatorChar,'/');
  }
  return path;
}

public static String toSystemIndependentPath ( String path ) { if ( File . separatorChar != '/' ) { path = path . replace ( File . separatorChar , '/' ) ; } return path ; }
converts a system - dependent path into a / - based path .
