22.24
java.io.File
THE PACKAGE JAVA.IO
22.24 The Class
java.io.File
A
File
 object contains a
path
, which is a character string that can be used to iden 
tify a file within a file system. A path is assumed to consist of two parts, the
direc 
tory
 and the
file name
, separated by the last occurrence within the path of a
particular character known as the
separator character
. Some methods provide
access to parts of the path string; other methods operate on the file that is identi 
fied by the path string. The details of such operations on files are to some extent
dependent on the implementation of the host file system. The
File
 class is
designed to provide a set of abstract operations that are reasonably portable across
otherwise incompatible file systems.
public class File {
public static final String separator =
System.getProperty("file.separator");
public static final char separatorChar =
separator.charAt(0);
public static final String pathSeparator =
System.getProperty("path.separator");
public static final char pathSeparatorChar =
pathSeparator.charAt(0);
public File(String path) throws NullPointerException;
public File(String dirname, String name)
throws NullPointerException
public File(File dir, String name)
throws NullPointerException
public String toString();
public boolean equals(Object obj);
public int hashCode();
public String getName();
public String getPath();
public String getAbsolutePath();
public String getParent();
public native boolean isAbsolute();
public boolean exists() throws SecurityException;
public boolean canRead() throws SecurityException;
public boolean canWrite() throws SecurityException;
public boolean isFile() throws SecurityException;
public boolean isDirectory() throws SecurityException;
public long lastModified() throws SecurityException;
public long length() throws SecurityException;
public boolean mkdir() throws SecurityException;
public boolean mkdirs() throws SecurityException;
public String[] list() throws SecurityException;
752






footer




 

 

 

 

 Home | About Us | Network | Services | Support | FAQ | Control Panel | Order Online | Sitemap | Contact

java hosting

 

Our partners: PHP: Hypertext Preprocessor Best Web Hosting Java Web Hosting Inexpensive Web Hosting  Jsp Web Hosting

Cheapest Web Hosting Jsp Hosting Cheap Hosting

Visionwebhosting.net Business web hosting division of Web Design Plus. All rights reserved