Package org.apache.poi.poifs.filesystem

Examples of org.apache.poi.poifs.filesystem.OfficeXmlFileException


      byte[] OOXML_FILE_HEADER = POIFSConstants.OOXML_FILE_HEADER;
      if(blockStart[0] == OOXML_FILE_HEADER[0] &&
        blockStart[1] == OOXML_FILE_HEADER[1] &&
        blockStart[2] == OOXML_FILE_HEADER[2] &&
        blockStart[3] == OOXML_FILE_HEADER[3]) {
        throw new OfficeXmlFileException("The supplied data appears to be in the Office 2007+ XML. You are calling the part of POI that deals with OLE2 Office Documents. You need to call a different part of POI to process this data (eg XSSF instead of HSSF)");
      }
      if ((signature & 0xFF8FFFFFFFFFFFFFL) == 0x0010000200040009L) {
        // BIFF2 raw stream starts with BOF (sid=0x0009, size=0x0004, data=0x00t0)
        throw new IllegalArgumentException("The supplied data appears to be in BIFF2 format.  "
            + "POI only supports BIFF8 format");
View Full Code Here


      byte[] OOXML_FILE_HEADER = POIFSConstants.OOXML_FILE_HEADER;
      if(_data[0] == OOXML_FILE_HEADER[0] &&
        _data[1] == OOXML_FILE_HEADER[1] &&
        _data[2] == OOXML_FILE_HEADER[2] &&
        _data[3] == OOXML_FILE_HEADER[3]) {
        throw new OfficeXmlFileException("The supplied data appears to be in the Office 2007+ XML. You are calling the part of POI that deals with OLE2 Office Documents. You need to call a different part of POI to process this data (eg XSSF instead of HSSF)");
      }
      if ((signature & 0xFF8FFFFFFFFFFFFFL) == 0x0010000200040009L) {
        // BIFF2 raw stream starts with BOF (sid=0x0009, size=0x0004, data=0x00t0)
        throw new IllegalArgumentException("The supplied data appears to be in BIFF2 format.  "
            + "POI only supports BIFF8 format");
View Full Code Here

          byte[] OOXML_FILE_HEADER = POIFSConstants.OOXML_FILE_HEADER;
      if(_data[0] == OOXML_FILE_HEADER[0] &&
          _data[1] == OOXML_FILE_HEADER[1] &&
          _data[2] == OOXML_FILE_HEADER[2] &&
          _data[3] == OOXML_FILE_HEADER[3]) {
        throw new OfficeXmlFileException("The supplied data appears to be in the Office 2007+ XML. POI only supports OLE2 Office documents");
      }

      // Give a generic error
            throw new IOException("Invalid header signature; read "
                                  + signature.get() + ", expected "
View Full Code Here

        if (signature.get() != _signature)
        {
      // Is it one of the usual suspects?
      if(_data[0] == 0x50 && _data[1] == 0x4b && _data[2] == 0x03 &&
          _data[3] == 0x04) {
        throw new OfficeXmlFileException("The supplied data appears to be in the Office 2007+ XML. POI only supports OLE2 Office documents");
      }

      // Give a generic error
            throw new IOException("Invalid header signature; read "
                                  + signature.get() + ", expected "
View Full Code Here

      byte[] OOXML_FILE_HEADER = POIFSConstants.OOXML_FILE_HEADER;
      if(_data[0] == OOXML_FILE_HEADER[0] &&
          _data[1] == OOXML_FILE_HEADER[1] &&
          _data[2] == OOXML_FILE_HEADER[2] &&
          _data[3] == OOXML_FILE_HEADER[3]) {
        throw new OfficeXmlFileException("The supplied data appears to be in the Office 2007+ XML. You are calling the part of POI that deals with OLE2 Office Documents. You need to call a different part of POI to process this data (eg XSSF instead of HSSF)");
      }
      if ((signature & 0xFF8FFFFFFFFFFFFFL) == 0x0010000200040009L) {
        // BIFF2 raw stream starts with BOF (sid=0x0009, size=0x0004, data=0x00t0)
        throw new IllegalArgumentException("The supplied data appears to be in BIFF2 format.  "
            + "POI only supports BIFF8 format");
View Full Code Here

      byte[] OOXML_FILE_HEADER = POIFSConstants.OOXML_FILE_HEADER;
      if(_data[0] == OOXML_FILE_HEADER[0] &&
        _data[1] == OOXML_FILE_HEADER[1] &&
        _data[2] == OOXML_FILE_HEADER[2] &&
        _data[3] == OOXML_FILE_HEADER[3]) {
        throw new OfficeXmlFileException("The supplied data appears to be in the Office 2007+ XML. You are calling the part of POI that deals with OLE2 Office Documents. You need to call a different part of POI to process this data (eg XSSF instead of HSSF)");
      }
      if ((signature & 0xFF8FFFFFFFFFFFFFL) == 0x0010000200040009L) {
        // BIFF2 raw stream starts with BOF (sid=0x0009, size=0x0004, data=0x00t0)
        throw new IllegalArgumentException("The supplied data appears to be in BIFF2 format.  "
            + "POI only supports BIFF8 format");
View Full Code Here

      byte[] OOXML_FILE_HEADER = POIFSConstants.OOXML_FILE_HEADER;
      if(blockStart[0] == OOXML_FILE_HEADER[0] &&
        blockStart[1] == OOXML_FILE_HEADER[1] &&
        blockStart[2] == OOXML_FILE_HEADER[2] &&
        blockStart[3] == OOXML_FILE_HEADER[3]) {
        throw new OfficeXmlFileException("The supplied data appears to be in the Office 2007+ XML. You are calling the part of POI that deals with OLE2 Office Documents. You need to call a different part of POI to process this data (eg XSSF instead of HSSF)");
      }
      if ((signature & 0xFF8FFFFFFFFFFFFFL) == 0x0010000200040009L) {
        // BIFF2 raw stream starts with BOF (sid=0x0009, size=0x0004, data=0x00t0)
        throw new IllegalArgumentException("The supplied data appears to be in BIFF2 format.  "
            + "POI only supports BIFF8 format");
View Full Code Here

          byte[] OOXML_FILE_HEADER = POIFSConstants.OOXML_FILE_HEADER;
      if(_data[0] == OOXML_FILE_HEADER[0] &&
          _data[1] == OOXML_FILE_HEADER[1] &&
          _data[2] == OOXML_FILE_HEADER[2] &&
          _data[3] == OOXML_FILE_HEADER[3]) {
        throw new OfficeXmlFileException("The supplied data appears to be in the Office 2007+ XML. You are calling the part of POI that deals with OLE2 Office Documents. You need to call a different part of POI to process this data (eg XSSF instead of HSSF)");
      }

      // Give a generic error
            throw new IOException("Invalid header signature; read "
                                  + signature.get() + ", expected "
View Full Code Here

          byte[] OOXML_FILE_HEADER = POIFSConstants.OOXML_FILE_HEADER;
      if(_data[0] == OOXML_FILE_HEADER[0] &&
          _data[1] == OOXML_FILE_HEADER[1] &&
          _data[2] == OOXML_FILE_HEADER[2] &&
          _data[3] == OOXML_FILE_HEADER[3]) {
        throw new OfficeXmlFileException("The supplied data appears to be in the Office 2007+ XML. POI only supports OLE2 Office documents");
      }

      // Give a generic error
            throw new IOException("Invalid header signature; read "
                                  + signature.get() + ", expected "
View Full Code Here

TOP

Related Classes of org.apache.poi.poifs.filesystem.OfficeXmlFileException

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.