java.lang.Object
ushiosan.jvm_utilities.internal.io.IOImpl
- Direct Known Subclasses:
IO
-
Field Summary
Fields -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionprotected static @NotNull FileSystemReturns a valid file system depending on the scheme of the given urlprotected static @NotNull FileSystemReturns a valid file system depending on the scheme of the given urlgetValidPath(@NotNull URI uri) Returns the path of an url in the file system (if the scheme is supported).getValidPath(@NotNull URL url) Returns the path of an url in the file system (if the scheme is supported).
-
Field Details
-
FILESYSTEM_ROOT
Filesystem path root- See Also:
-
-
Constructor Details
-
IOImpl
protected IOImpl()This class cannot be instantiated.Singleton or utility class mode.
-
-
Method Details
-
getValidFilesystem
@NotNull protected static @NotNull FileSystem getValidFilesystem(@NotNull @NotNull URL url) throws IOException Returns a valid file system depending on the scheme of the given url- Parameters:
url- the url to inspect- Returns:
- valid filesystem
- Throws:
IOException- error if url schema is not supported
-
getValidFilesystem
@NotNull protected static @NotNull FileSystem getValidFilesystem(@NotNull @NotNull URI uri) throws IOException Returns a valid file system depending on the scheme of the given url- Parameters:
uri- the url to inspect- Returns:
- valid filesystem
- Throws:
IOException- error if url schema is not supported
-
getValidPath
Returns the path of an url in the file system (if the scheme is supported).If the schema is a jar file, the virtual representation of the file as a directory will be returned.
- Parameters:
url- the url to inspect- Returns:
- a valid file path
- Throws:
IOException- error if given url is not supported
-
getValidPath
Returns the path of an url in the file system (if the scheme is supported).If the schema is a jar file, the virtual representation of the file as a directory will be returned.
- Parameters:
uri- the url to inspect- Returns:
- a valid file path
- Throws:
IOException- error if given url is not supported
-