Package org.jrd.backend.decompiling
Class ExpandableUrl
- java.lang.Object
-
- org.jrd.backend.decompiling.ExpandableUrl
-
public class ExpandableUrl extends Object
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description static classExpandableUrl.MalformedMacroExpansionstatic classExpandableUrl.MalformedURLToPath
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description static ExpandableUrlcreateFromPath(String path)static ExpandableUrlcreateFromStringUrl(String url)StringgetExpandedPath()URLgetExpandedURL()FilegetFile()StringgetRawPath()StringgetRawURL()protected static StringprependFileProtocol(String url)There were many differences in file protocol handling between jdk8 and jdk11.StringtoString()static StringunifySlashes(String dir)static StringunifySlashes(String dir, boolean prependSlash)
-
-
-
Method Detail
-
createFromPath
public static ExpandableUrl createFromPath(String path)
-
createFromStringUrl
public static ExpandableUrl createFromStringUrl(String url) throws ExpandableUrl.MalformedMacroExpansion
-
prependFileProtocol
protected static String prependFileProtocol(String url)
There were many differences in file protocol handling between jdk8 and jdk11. Especially on windows, Where redundant / could auto point to C:\ or simply kill the path Although this method shoul be of signature URL:(File), it was left as String String, as the slashes are making us mad- Parameters:
url-- Returns:
-
getExpandedURL
public URL getExpandedURL() throws MalformedURLException
- Throws:
MalformedURLException
-
getRawURL
public String getRawURL()
-
getExpandedPath
public String getExpandedPath()
-
getRawPath
public String getRawPath()
-
getFile
public File getFile()
-
-