Class XFileContents

  • All Implemented Interfaces:
    FileContents

    class XFileContents
    extends java.lang.Object
    implements FileContents
    File contents.
    Version:
    $Revision: 1.6 $
    • Field Detail

      • file

        private java.io.File file
        the file
    • Constructor Detail

      • XFileContents

        protected XFileContents​(java.io.File file)
        Create a file contents implementation for the file.
    • Method Detail

      • canRead

        public boolean canRead()
                        throws java.io.IOException
        Specified by:
        canRead in interface FileContents
        Throws:
        java.io.IOException - if an I/O exception occurs.
      • canWrite

        public boolean canWrite()
                         throws java.io.IOException
        Specified by:
        canWrite in interface FileContents
        Throws:
        java.io.IOException - if an I/O exception occurs.
      • getInputStream

        public java.io.InputStream getInputStream()
                                           throws java.io.IOException
        Specified by:
        getInputStream in interface FileContents
        Throws:
        java.io.IOException - if an I/O exception occurs.
      • getLength

        public long getLength()
                       throws java.io.IOException
        Specified by:
        getLength in interface FileContents
        Throws:
        java.io.IOException - if an I/O exception occurs.
      • getMaxLength

        public long getMaxLength()
                          throws java.io.IOException
        Specified by:
        getMaxLength in interface FileContents
        Throws:
        java.io.IOException - if an I/O exception occurs.
      • getName

        public java.lang.String getName()
                                 throws java.io.IOException
        Specified by:
        getName in interface FileContents
        Throws:
        java.io.IOException - if an I/O exception occurs.
      • getOutputStream

        public java.io.OutputStream getOutputStream​(boolean overwrite)
                                             throws java.io.IOException
        Specified by:
        getOutputStream in interface FileContents
        Throws:
        java.io.IOException - if an I/O exception occurs.
      • setMaxLength

        public long setMaxLength​(long maxlength)
                          throws java.io.IOException
        Specified by:
        setMaxLength in interface FileContents
        Throws:
        java.io.IOException - if an I/O exception occurs.