java.lang.Object
com.intellij.openapi.util.URLUtil
-
字段概要
字段 -
方法概要
修饰符和类型方法说明static @NotNull InputStreamopenStream(@NotNull URL url) Opens a url stream.splitJarUrl(@NotNull String url) Splits .jar URL along a separator and strips "jar" and "file" prefixes if any.static @NotNull File
-
字段详细资料
-
方法详细资料
-
openStream
@NotNull public static @NotNull InputStream openStream(@NotNull @NotNull URL url) throws IOException Opens a url stream. The semantics is the sames asURL.openStream(). The separate method is needed, since jar URLs open jars via JarFactory and thus keep them mapped into memory.- 抛出:
IOException
-
splitJarUrl
Splits .jar URL along a separator and strips "jar" and "file" prefixes if any. Returns a pair of path to a .jar file and entry name inside a .jar, or null if the URL does not contain a separator. E.g. "jar:file:///path/to/jar.jar!/resource.xml" is converted into ["/path/to/jar.jar", "resource.xml"]. Please note that the first part is platform-dependent - see UrlUtilTest.testJarUrlSplitter() for examples. -
urlToFile
-