/** * Constructs this object from the raw data * * @param t the raw data * @param ws the workbook settings */ public SupbookRecord(Record t, WorkbookSettings ws) : base(t) { byte[] data = getRecord().getData(); // First deduce the type if (data.Length == 4) { if (data[2] == 0x01 && data[3] == 0x04) { type = INTERNAL; } else if (data[2] == 0x01 && data[3] == 0x3a) { type = ADDIN; } else { type = UNKNOWN; } } else if (data[0] == 0 && data[1] == 0) { type = LINK; } else { type = EXTERNAL; } if (type == INTERNAL) { numSheets = IntegerHelper.getInt(data[0], data[1]); } if (type == EXTERNAL) { readExternal(data, ws); } }
/** * Constructs this object from the raw data * * @param t the raw data * @param ws the workbook settings */ public SupbookRecord(Record t, WorkbookSettings ws) : base(t) { byte[] data = getRecord().getData(); // First deduce the type if (data.Length == 4) { if (data[2] == 0x01 && data[3] == 0x04) { type = INTERNAL; } else if (data[2] == 0x01 && data[3] == 0x3a) { type = ADDIN; } else { type = UNKNOWN; } } else if (data[0] == 0 && data[1] == 0) { type = LINK; } else { type = EXTERNAL; } if (type == INTERNAL) { numSheets = IntegerHelper.getInt(data[0],data[1]); } if (type == EXTERNAL) { readExternal(data,ws); } }