public class RemoteFile extends FileAdapter
ClosedFolderIcon, DOS_SYSTEM, DriveIcon, FileIcon, FLAG_CASE_SENSITIVE, FLAG_FILE_SYSTEM_IS_READ_ONLY, FLAG_READ_ONLY, FLAG_SLOW_ACCESS, FLAG_SLOW_CHILD_COUNT, FLAG_SLOW_LIST, INFO_CREATE_TEMP, INFO_CURRENT_DIRECTORY, INFO_DETAIL_NAMES, INFO_DETAIL_WIDTHS, INFO_DETAILS, INFO_DEVICE_ICON, INFO_DEVICE_NAME, INFO_FILE_TIMES, INFO_FLAGS, INFO_FREE_DRIVE_SPACE, INFO_GROUP, INFO_ICON, INFO_LINK_DESTINATION, INFO_OPTION_ICON_LARGE, INFO_OPTION_ICON_MEDIUM, INFO_OPTION_ICON_SMALL, INFO_OWNER, INFO_PROGRAM_DIRECTORY, INFO_ROOT_LIST, INFO_SET_USER_AND_GROUP, INFO_SYMBOLIC_LINK_TARGET, INFO_SYSTEM_TYPE, INFO_TEMPORARY_DIRECTORY, INFO_TOOL_TIP, INFO_TOTAL_DRIVE_SPACE, INFO_VOLUME_FLAGS, INFO_VOLUME_LIST, INFO_VOLUME_PROPERTIES, LIST_ALWAYS_INCLUDE_DIRECTORIES, LIST_BY_DATE, LIST_BY_NAME, LIST_BY_SIZE, LIST_BY_TYPE, LIST_CHECK_FOR_ANY_MATCHING_CHILDREN, LIST_DESCENDING, LIST_DIRECTORIES_FIRST, LIST_DIRECTORIES_LAST, LIST_DIRECTORIES_ONLY, LIST_DONT_LIST_HIDDEN_FILES, LIST_DONT_SORT, LIST_FILES_ONLY, LIST_IGNORE_DIRECTORY_STATUS, MEMORY_SYSTEM, OpenFolderIcon, PageIcon, PALM_SYSTEM, pathSeparator, pathSeparatorChar, separator, separatorChar, UNIX_SYSTEM
VOLUME_FLAG_CDROM, VOLUME_FLAG_FIXED, VOLUME_FLAG_NETWORK, VOLUME_FLAG_RAM, VOLUME_FLAG_REMOVABLE, VOLUME_PROPERTY_BYTES_FREE, VOLUME_PROPERTY_BYTES_TOTAL, VOLUME_PROPERTY_FILESYSTEM_NAME, VOLUME_PROPERTY_NAME
ALL_DOS_FLAGS, ALL_UNIX_PERMISSIONS, FLAG_ARCHIVE, FLAG_HIDDEN, FLAG_READONLY, FLAG_ROM, FLAG_ROMMODULE, FLAG_SYSTEM, FLAG_WINDOWS_ALL_USERS_ACCESS, GROUP_EXECUTE, GROUP_READ, GROUP_WRITE, OTHER_EXECUTE, OTHER_READ, OTHER_WRITE, OWNER_EXECUTE, OWNER_READ, OWNER_WRITE
Constructor and Description |
---|
RemoteFile() |
Modifier and Type | Method and Description |
---|---|
boolean |
createDir()
Creates a directory.
|
boolean |
delete()
Deletes the file or directory.
|
void |
deleteOnExit()
This tells the system to delete the file when the program exits.
|
boolean |
exists()
Returns true if the file exists and false otherwise.
|
String |
getFullPath()
Return the fully qualified pathname of the file.
|
long |
getLength() |
protected File |
getNewInstance()
Get a new instance of this File().
|
protected long |
getSetModified(long time,
boolean doGet)
This gets/sets the modified time of the file.
|
boolean |
isDirectory()
Returns true if the file is a directory and false otherwise.
|
String[] |
list(String mask,
int listAndSortOptions)
Lists the files contained in a directory.
|
boolean |
move(File newFile)
This moves/renames the file to the destination new File.
|
canRead, canWrite, createSymbolicLink, getInfo, getSetPermissionsAndFlags, getSupportedPermissionsAndFlags, getSymbolicLinkTarget, isSymbolicLink, list, set, setFullPathName, setInfo, toJavaFile, toRandomStream
allowAllUsersFullAccess, changePermissionsAndFlags, chmod, chown, createNewFile, createTempFile, createTempFile, equals, filePathsAreEqual, fixupPath, getAbsoluteFile, getAbsolutePath, getBestFileChooser, getCanonicalFile, getCanonicalPath, getChild, getChild, getCopy, getCreationName, getCreationName, getDefaultRoot, getDrivePath, getDrivePath, getFileExt, getFileExt, getFlags, getGroup, getIcon, getInfo, getModified, getName, getNew, getNew, getNewFile, getNewFile, getNewFile, getOwner, getParent, getParentFile, getPermissionsAndFlags, getProgramDirectory, getPropertiesString, getSetInfo, getText, getTrueChild, getTrueParent, hashCode, isAbsolute, isFile, isHidden, isSameFileSystem, isSameVolume, lastModified, list, list, listMultiple, listRoots, listVolumes, makePath, makePath, mkdir, mkdirs, refresh, removeTrailingSlash, removeTrailingSlash, rename, renameTo, roots, setExecutable, setJavaFile, setJavaFile, setLastModified, setModified, setPermissionsAndFlags, setReadable, setReadOnly, setText, setWritable, toReadableStream, toString, toSystemDependantPath, toWritableStream, volumeFlags, volumeProperties, volumes
protected File getNewInstance()
File
getNewInstance
in class FileAdapter
public boolean createDir()
File
createDir
in class FileAdapter
public boolean delete()
File
delete
in class FileAdapter
public boolean exists()
File
exists
in class FileAdapter
public boolean isDirectory()
File
isDirectory
in class FileAdapter
public String getFullPath()
File
getFullPath
in class FileAdapter
public void deleteOnExit()
File
deleteOnExit
in class FileAdapter
public String[] list(String mask, int listAndSortOptions)
File
The default method calls the list() method and then splits the returned char array.
list
in class FileAdapter
mask
- A file mask.listAndSortOptions
- Use the LIST_XXX values OR'ed together.protected long getSetModified(long time, boolean doGet) throws IOException
File
getSetModified
in class FileAdapter
IOException
public boolean move(File newFile)
File
move
in class FileAdapter
public long getLength()
getLength
in class FileAdapter