public static String getFileNameFromPath(String path)
    {
	if(Common.notNullOrEmpty(path) && Common.isPathValid(path))
	{
	    File file = new File(path);
	    String fileName = file.getName();

	    if(Common.notNullOrEmpty(fileName))
	    {
		// Get the path to the parent directory.
		return fileName;
	    }else { return path; }
	}
	else { return path; }
    }