java.lang.Object
org.gjt.sp.jedit.io.VFS
org.gjt.sp.jedit.io.UrlVFS
URL VFS.
- Version:
- $Id: UrlVFS.java 25000 2020-03-21 19:40:09Z kpouer $
- Author:
- Slava Pestov
-
Nested Class Summary
Nested classes/interfaces inherited from class org.gjt.sp.jedit.io.VFS
VFS.DirectoryEntryCompare
-
Field Summary
Fields inherited from class org.gjt.sp.jedit.io.VFS
BROWSE_CAP, CASE_INSENSITIVE_CAP, DELETE_CAP, EA_MODIFIED, EA_SIZE, EA_STATUS, EA_TYPE, IOBUFSIZE, LOW_LATENCY_CAP, MKDIR_CAP, NON_AWT_SESSION_CAP, READ_CAP, RENAME_CAP, WRITE_CAP
-
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescription_createInputStream
(Object session, String path, boolean ignoreErrors, Component comp) Creates an input stream._createOutputStream
(Object session, String path, Component comp) Creates an output stream.constructPath
(String parent, String path) Constructs a path from the specified directory and file name component.getFilePath
(String vfsPath) Returns the path component of the specified VFS path.Methods inherited from class org.gjt.sp.jedit.io.VFS
_backup, _canonPath, _delete, _endVFSSession, _finishTwoStageSave, _getFile, _listDirectory, _listDirectory, _listDirectory, _listFiles, _mkdir, _rename, _saveComplete, copy, copy, copy, copy, createVFSSession, createVFSSessionSafe, getCapabilities, getDefaultColorFor, getDefaultEncoding, getExtendedAttributes, getFileName, getFileSeparator, getName, getParentOfPath, getTwoStageSaveName, insert, isMarkersFileSupported, load, reloadDirectory, save, setEncoding
-
Constructor Details
-
UrlVFS
public UrlVFS()
-
-
Method Details
-
constructPath
Description copied from class:VFS
Constructs a path from the specified directory and file name component. This must be overridden to return a non-null value, otherwise browsing this filesystem will not work.Unless you are writing a VFS, this method should not be called directly. To ensure correct behavior, you must call
MiscUtilities.constructPath(String,String)
instead.- Overrides:
constructPath
in classVFS
- Parameters:
parent
- The parent directorypath
- The path
-
_createInputStream
public InputStream _createInputStream(Object session, String path, boolean ignoreErrors, Component comp) throws IOException Description copied from class:VFS
Creates an input stream. This method is called from the I/O thread.- Overrides:
_createInputStream
in classVFS
- Parameters:
session
- the VFS sessionpath
- The pathignoreErrors
- If true, file not found errors should be ignoredcomp
- The component that will parent error dialog boxes- Returns:
- an inputstream or
null
if there was a problem - Throws:
IOException
- If an I/O error occurs
-
_createOutputStream
public OutputStream _createOutputStream(Object session, String path, Component comp) throws IOException Description copied from class:VFS
Creates an output stream. This method is called from the I/O thread.- Overrides:
_createOutputStream
in classVFS
- Parameters:
session
- the VFS sessionpath
- The pathcomp
- The component that will parent error dialog boxes- Throws:
IOException
- If an I/O error occurs
-
getFilePath
Description copied from class:VFS
Returns the path component of the specified VFS path. The standard implementation cuts off the protocol and the protocol separator character and then delegates to eventually present sub-VFS-paths present in the VFS path like "jode:archive:/test.zip!/test.txt".If a VFS implementation can have additional information in the VFS path like username / password / host / port for FTP VFS or archive filename for archive VFS, this method should be overridden to remove those information also. The easiest would be to remove those additional information and then delegate to
super.getFilePath()
.- Overrides:
getFilePath
in classVFS
- Parameters:
vfsPath
- The VFS path
-