FileDocCategorySizeDatePackage
ForwardingFileObject.javaAPI DocJava SE 6 API2885Tue Jun 10 00:27:02 BST 2008javax.tools

ForwardingFileObject

public class ForwardingFileObject extends Object implements FileObject
Forwards calls to a given file object. Subclasses of this class might override some of these methods and might also provide additional fields and methods.
param
the kind of file object forwarded to by this object
author
Peter von der Ahé
since
1.6

Fields Summary
protected final F
fileObject
The file object which all methods are delegated to.
Constructors Summary
protected ForwardingFileObject(F fileObject)
Creates a new instance of ForwardingFileObject.

param
fileObject delegate to this file object

        fileObject.getClass(); // null check
        this.fileObject = fileObject;
    
Methods Summary
public booleandelete()

        return fileObject.delete();
    
public java.lang.CharSequencegetCharContent(boolean ignoreEncodingErrors)

throws
IllegalStateException {@inheritDoc}
throws
UnsupportedOperationException {@inheritDoc}
throws
IOException {@inheritDoc}

        return fileObject.getCharContent(ignoreEncodingErrors);
    
public longgetLastModified()

        return fileObject.getLastModified();
    
public java.lang.StringgetName()

        return fileObject.getName();
    
public java.io.InputStreamopenInputStream()

throws
IllegalStateException {@inheritDoc}
throws
UnsupportedOperationException {@inheritDoc}
throws
IOException {@inheritDoc}

        return fileObject.openInputStream();
    
public java.io.OutputStreamopenOutputStream()

throws
IllegalStateException {@inheritDoc}
throws
UnsupportedOperationException {@inheritDoc}
throws
IOException {@inheritDoc}

        return fileObject.openOutputStream();
    
public java.io.ReaderopenReader(boolean ignoreEncodingErrors)

throws
IllegalStateException {@inheritDoc}
throws
UnsupportedOperationException {@inheritDoc}
throws
IOException {@inheritDoc}

        return fileObject.openReader(ignoreEncodingErrors);
    
public java.io.WriteropenWriter()

throws
IllegalStateException {@inheritDoc}
throws
UnsupportedOperationException {@inheritDoc}
throws
IOException {@inheritDoc}

        return fileObject.openWriter();
    
public java.net.URItoUri()

        return fileObject.toUri();