public abstract class FileStoreEntryFile extends FileAdapter
Modifier and Type | Field and Description |
---|---|
FileStoreEntry |
myEntry |
FileStoreEntry |
root |
FileStore |
store |
String |
storeName |
ClosedFolderIcon, DOS_SYSTEM, DriveIcon, FileIcon, FLAG_CASE_SENSITIVE, FLAG_FILE_SYSTEM_IS_READ_ONLY, FLAG_IS_NETWORK_COMPUTER, FLAG_IS_NETWORK_ROOT, FLAG_IS_ON_NETWORK, 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
Modifier | Constructor and Description |
---|---|
protected |
FileStoreEntryFile(FileStore store) |
|
FileStoreEntryFile(FileStore fs,
Handle h) |
Modifier and Type | Method and Description |
---|---|
boolean |
createDir() |
protected abstract FileStoreEntryFile |
createNew(FileStore store) |
static FileStoreEntry |
createTree(FileStoreEntryFile dest,
FileStore store,
Handle handle) |
boolean |
delete() |
void |
deleteOnExit() |
protected void |
endFind(int search) |
boolean |
exists() |
protected Object |
findNext(int search) |
String |
getFullPath() |
Wrapper |
getInfo(int infoCode,
Wrapper sourceParameters,
int options) |
long |
getLength() |
File |
getNew(File parent,
String file)
Get a new File object given the directory and new path.
|
protected long |
getSetModified(long time,
boolean doGet) |
boolean |
isDirectory() |
boolean |
isValid() |
String[] |
list(String mask,
int listAndSortOptions)
Lists the files contained in a directory.
|
boolean |
move(File newFile) |
void |
set(File parent,
String file)
Modifies the File to point to a different file on the file system.
|
protected int |
startFind(String mask) |
RandomStream |
toRandomStream(String mode)
Create and return a RandomAccessStream for reading/writing to the data associated with this File object.
|
InputStream |
toReadableStream()
Create and return a Stream to use for reading from the File.
|
OutputStream |
toWritableStream(boolean append)
Create and return a Stream to use for writing to the File.
|
canRead, canWrite, createSymbolicLink, getNewInstance, getSetPermissionsAndFlags, getSupportedPermissionsAndFlags, getSymbolicLinkTarget, isSymbolicLink, list, setFullPathName, setInfo, toJavaFile
_jfilegetAbsolutePath, 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, 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, toString, toSystemDependantPath, volumeFlags, volumeProperties, volumes
public FileStoreEntry root
public FileStoreEntry myEntry
public FileStore store
public String storeName
protected FileStoreEntryFile(FileStore store)
public boolean isValid()
public boolean exists()
exists
in class FileAdapter
public boolean isDirectory()
isDirectory
in class FileAdapter
public long getLength()
getLength
in class FileAdapter
protected abstract FileStoreEntryFile createNew(FileStore store)
public File getNew(File parent, String file)
File
public static FileStoreEntry createTree(FileStoreEntryFile dest, FileStore store, Handle handle)
public void set(File parent, String file)
File
set
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 int startFind(String mask)
protected Object findNext(int search)
protected void endFind(int search)
public Wrapper getInfo(int infoCode, Wrapper sourceParameters, int options)
getInfo
in class FileAdapter
protected long getSetModified(long time, boolean doGet) throws IOException
getSetModified
in class FileAdapter
IOException
public boolean move(File newFile)
move
in class FileAdapter
public boolean createDir()
createDir
in class FileAdapter
public boolean delete()
delete
in class FileAdapter
public String getFullPath()
getFullPath
in class FileAdapter
public void deleteOnExit()
deleteOnExit
in class FileAdapter
public InputStream toReadableStream() throws IOException
File
toReadableStream
in class File
IOException
- if an open stream could not be created.public RandomStream toRandomStream(String mode) throws IOException
FileAdapter
toRandomStream
in class FileAdapter
mode
- must be "r" or "rw".IOException
- if an open stream could not be created.public OutputStream toWritableStream(boolean append) throws IOException
File
toWritableStream
in class File
append
- set this true if you want to append to the existing file.IOException
- if an open stream could not be created, or if the file exists but could not
be written to or erased (if not appending), or if you requested append but append mode is not supported
for this File.