Package org.apache.poi.hssf.record

Examples of org.apache.poi.hssf.record.RecordFormatException


          // if there is only one
          // records, it will go here too.
        }
        else
          {
                                  throw new RecordFormatException("Records should handle ContinueRecord internally. Should not see this exception");
        }
      }
      if (rec != null)
      {
        userCode = req.processRecord(rec);
View Full Code Here


                {
                } );
            }
            catch ( Exception illegalArgumentException )
            {
                throw new RecordFormatException(
                        "Unable to determine record types" );
            }
            result.put( new Short( sid ), constructor );
        }
        return result;
View Full Code Here

                retval = new UnknownRecord(in);
            }
        }
        catch (Exception introspectionException)
        {
            throw new RecordFormatException("Unable to construct record instance" , introspectionException);
        }
        if (retval instanceof RKRecord)
        {
            RKRecord     rk  = ( RKRecord ) retval;
            NumberRecord num = new NumberRecord();
View Full Code Here

                    RecordInputStream.class
                });
            }
            catch (Exception illegalArgumentException)
            {
                throw new RecordFormatException(
                    "Unable to determine record types");
            }
            result.put(new Short(sid), constructor);
        }
        return result;
View Full Code Here

            field_5_fileIdClusters[i] = new FileIdCluster(LittleEndian.getInt( data, pos + size ), LittleEndian.getInt( data, pos + size + 4 ));
            size += 8;
        }
        bytesRemaining         -= size;
        if (bytesRemaining != 0)
            throw new RecordFormatException("Expecting no remaining data but got " + bytesRemaining + " byte(s).");
        return 8 + size + bytesRemaining;
    }
View Full Code Here

        field_2_color2 =  LittleEndian.getInt( data, pos + size );size+=4;
        field_3_color3 =  LittleEndian.getInt( data, pos + size );size+=4;
        field_4_color4 =  LittleEndian.getInt( data, pos + size );size+=4;
        bytesRemaining -= size;
        if (bytesRemaining != 0)
            throw new RecordFormatException("Expecting no remaining data but got " + bytesRemaining + " byte(s).");
        return 8 + size + bytesRemaining;
    }
View Full Code Here

                {
                } );
            }
            catch ( Exception illegalArgumentException )
            {
                throw new RecordFormatException(
                        "Unable to determine record types" );
            }
            result.put( new Short( sid ), constructor );
        }
        return result;
View Full Code Here

      return field_2_first_col;
    }   

    public String toFormulaString(HSSFWorkbook book)
    {
        throw new RecordFormatException("Coding Error: Expected ExpPtg to be converted from Shared to Non-Shared Formula by ValueRecordsAggregate, but it wasn't");
    }
View Full Code Here

        if (userCode != 0) break process;
      }
    }
    catch (IOException e)
    {
      throw new RecordFormatException("Error reading bytes" +
                        "while processing record sid="+sid);
    }
    return userCode;

    // Record[] retval = new Record[ records.size() ];
View Full Code Here

                                ! (last_record instanceof ContinueRecord) && // include continuation records after
                                ! (last_record instanceof UnknownRecord) )   // unknown records or previous continuation records
                            {
                                if (last_record == null)
                                {
                                    throw new RecordFormatException(
                                        "First record is a ContinueRecord??");
                                }
                                last_record.processContinueRecord(data);
                            }
                            else
                            {
                                if (last_record != null) {
                                    if (throwRecordEvent(last_record) == false && abortable == true) {
                                        last_record = null;
                                        break;  
                                    }
                                }
                               
                                last_record = record;
                               
                                //records.add(record);
                            }
                        }
                    }
                }
            }
            while (rectype != 0);
           
            if (last_record != null) {
               throwRecordEvent(last_record);              
            }
        }
        catch (IOException e)
        {
            throw new RecordFormatException("Error reading bytes");
        }

        // Record[] retval = new Record[ records.size() ];
        // retval = ( Record [] ) records.toArray(retval);
    
View Full Code Here

TOP

Related Classes of org.apache.poi.hssf.record.RecordFormatException

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.