PHPExcel_Writer_Excel5
[ class tree: PHPExcel_Writer_Excel5 ] [ index: PHPExcel_Writer_Excel5 ] [ all elements ]

Class: PHPExcel_Writer_Excel5_Workbook

Source Location: /PHPExcel/Writer/Excel5/Workbook.php

Class Overview

PHPExcel_Writer_Excel5_BIFFwriter
   |
   --PHPExcel_Writer_Excel5_Workbook

PHPExcel_Writer_Excel5_Workbook


Author(s):

Copyright:

  • Copyright (c) 2006 - 2010 PHPExcel (http://www.codeplex.com/PHPExcel)

Variables

Methods


Inherited Variables

Inherited Methods

Class: PHPExcel_Writer_Excel5_BIFFwriter

PHPExcel_Writer_Excel5_BIFFwriter::__construct()
Constructor
PHPExcel_Writer_Excel5_BIFFwriter::getByteOrder()
Determine the byte order and store it as class data to avoid recalculating it for each call to new().
PHPExcel_Writer_Excel5_BIFFwriter::writeData()
General storage function like _append, but returns string instead of modifying $this->_data
PHPExcel_Writer_Excel5_BIFFwriter::writeEof()
Writes Excel EOF record to indicate the end of a BIFF stream.
PHPExcel_Writer_Excel5_BIFFwriter::_addContinue()
Excel limits the size of BIFF records. Excel 97 the limit is 8228 bytes. must be split up into CONTINUE blocks.
PHPExcel_Writer_Excel5_BIFFwriter::_append()
General storage function
PHPExcel_Writer_Excel5_BIFFwriter::_storeBof()
Writes Excel BOF record to indicate the beginning of a stream or sub-stream in the BIFF file.
PHPExcel_Writer_Excel5_BIFFwriter::_storeEof()
Writes Excel EOF record to indicate the end of a BIFF stream.

Class Details

[line 119]
PHPExcel_Writer_Excel5_Workbook

PHPExcel_Writer_Excel5_Workbook




Tags:

copyright:  Copyright (c) 2006 - 2010 PHPExcel (http://www.codeplex.com/PHPExcel)


[ Top ]


Class Variables

$_addedFonts = array()

[line 183]

Added fonts.

Added fonts. Maps from font's hash => index in workbook




Tags:

access:  private

Type:   array


[ Top ]

$_addedNumberFormats = array()

[line 197]

Added number formats.

Added number formats. Maps from numberFormat's hash => index in workbook




Tags:

access:  private

Type:   array


[ Top ]

$_biffsize =

[line 133]

The BIFF file size for the workbook.

The BIFF file size for the workbook.




Tags:


Type:   integer


[ Top ]

$_codepage =

[line 151]

The codepage indicates the text encoding used for strings

The codepage indicates the text encoding used for strings




Tags:

access:  private

Type:   integer


[ Top ]

$_colors =

[line 237]

Color cache

Color cache




Tags:

access:  private

Type:   mixed


[ Top ]

$_country_code =

[line 157]

The country code used for localization

The country code used for localization




Tags:

access:  private

Type:   integer


[ Top ]

$_fontWriters = array()

[line 176]

Fonts writers

Fonts writers




Tags:

access:  private

Type:   PHPExcel_Writer_Excel5_Font[]


[ Top ]

$_numberFormats = array()

[line 190]

Shared number formats

Shared number formats




Tags:

access:  private

Type:   array


[ Top ]

$_palette =

[line 145]

Array containing the colour palette

Array containing the colour palette




Tags:

access:  private

Type:   array


[ Top ]

$_parser =

[line 126]

Formula parser

Formula parser




Tags:

access:  private



[ Top ]

$_phpExcel =

[line 169]

Workbook

Workbook




Tags:

access:  private

Type:   PHPExcel


[ Top ]

$_str_table =

[line 232]

Array of unique shared strings in workbook

Array of unique shared strings in workbook




Tags:

access:  private

Type:   array


[ Top ]

$_str_total =

[line 218]

Total number of shared strings in workbook

Total number of shared strings in workbook




Tags:

access:  private

Type:   int


[ Top ]

$_str_unique =

[line 225]

Number of unique shared strings in workbook

Number of unique shared strings in workbook




Tags:

access:  private

Type:   int


[ Top ]

$_tmp_dir =

[line 163]

The temporary dir for storing the OLE file

The temporary dir for storing the OLE file




Tags:

access:  private

Type:   string


[ Top ]

$_worksheetOffsets = array()

[line 211]

Offsets of the binary worksheet streams relative to the start of the global workbook stream

Offsets of the binary worksheet streams relative to the start of the global workbook stream




Tags:

access:  private

Type:   array


[ Top ]

$_worksheetSizes = array()

[line 204]

Sizes of the binary worksheet streams

Sizes of the binary worksheet streams




Tags:

access:  private

Type:   array


[ Top ]

$_xfWriters = array()

[line 139]

XF Writers

XF Writers




Tags:

access:  private

Type:   PHPExcel_Writer_Excel5_Xf[]


[ Top ]



Class Methods


constructor __construct [line 250]

PHPExcel_Writer_Excel5_Workbook __construct( [ $phpExcel = null], [ $BIFF_version = 0x0600], &$str_total, &$str_unique, &$str_table, &$colors, mixed $parser, [ $tempDir = ''], int $BIFF_verions, int $str_total, int $str_unique, array $str_table)

Class constructor

Class constructor




Tags:

access:  public


Overrides PHPExcel_Writer_Excel5_BIFFwriter::__construct() (Constructor)

Parameters:

PHPExcel   $phpExcel   The Workbook
int   $BIFF_verions   BIFF version
int   $str_total   Total number of strings
int   $str_unique   Total number of unique strings
array   $str_table  
mixed   $parser   The formula parser created for the Workbook
   $BIFF_version  
   &$str_total  
   &$str_unique  
   &$str_table  
   &$colors  
   $tempDir  

[ Top ]

method addXfWriter [line 315]

int addXfWriter( PHPExcel_Style $style, [boolean $isStyleXf = false])

Add a new XF writer

Add a new XF writer




Tags:

return:  Index to XF record
access:  public


Parameters:

PHPExcel_Style   $style  
boolean   $isStyleXf   Is it a style XF?

[ Top ]

method writeWorkbook [line 480]

string writeWorkbook( [ $pWorksheetSizes = null], array $worksheetSizes)

Assemble worksheets into a workbook and send the BIFF data to an OLE storage.

Assemble worksheets into a workbook and send the BIFF data to an OLE storage.




Tags:

return:  Binary data for workbook stream
access:  public


Parameters:

array   $worksheetSizes   The sizes in bytes of the binary worksheet streams
   $pWorksheetSizes  

[ Top ]

method _addColor [line 381]

int _addColor( string $rgb)

Alter color palette adding a custom color

Alter color palette adding a custom color




Tags:

return:  Color index
access:  private


Parameters:

string   $rgb   E.g. 'FF00AA'

[ Top ]

method _calcSheetOffsets [line 544]

void _calcSheetOffsets( )

Calculate offsets for Worksheet BOF records.

Calculate offsets for Worksheet BOF records.




Tags:

access:  private


[ Top ]

method _setPaletteXl97 [line 411]

void _setPaletteXl97( )

Sets the colour palette to the Excel 97+ default.

Sets the colour palette to the Excel 97+ default.




Tags:

access:  private


[ Top ]

method _storeAllFonts [line 578]

void _storeAllFonts( )

Store the Excel FONT records.

Store the Excel FONT records.




Tags:

access:  private


[ Top ]

method _storeAllNumFormats [line 590]

void _storeAllNumFormats( )

Store user defined numerical formats i.

Store user defined numerical formats i.e. FORMAT records




Tags:

access:  private


[ Top ]

method _storeAllStyles [line 614]

void _storeAllStyles( )

Write all STYLE records.

Write all STYLE records.




Tags:

access:  private


[ Top ]

method _storeAllXfs [line 602]

void _storeAllXfs( )

Write all XF records.

Write all XF records.




Tags:

access:  private


[ Top ]

method _storeBoundsheet [line 948]

void _storeBoundsheet( PHPExcel_Worksheet $sheet, integer $offset)

Writes Excel BIFF BOUNDSHEET record.

Writes Excel BIFF BOUNDSHEET record.




Tags:

access:  private


Parameters:

PHPExcel_Worksheet   $sheet   Worksheet name
integer   $offset   Location of worksheet BOF

[ Top ]

method _storeCodepage [line 895]

void _storeCodepage( )

Stores the CODEPAGE biff record.

Stores the CODEPAGE biff record.




Tags:

access:  private


[ Top ]

method _storeDatemode [line 1068]

void _storeDatemode( )

Write DATEMODE record to indicate the date system in use (1904 or 1900).

Write DATEMODE record to indicate the date system in use (1904 or 1900).




Tags:

access:  private


[ Top ]

method _storeExterncount [line 1095]

void _storeExterncount( integer $cxals)

Write BIFF record EXTERNCOUNT to indicate the number of external sheet references in the workbook.

Write BIFF record EXTERNCOUNT to indicate the number of external sheet references in the workbook. Excel only stores references to external sheets that are used in NAME. The workbook NAME record is required to define the print area and the repeat rows and columns. A similar method is used in Worksheet.php for a slightly different purpose.




Tags:

access:  private


Parameters:

integer   $cxals   Number of external references

[ Top ]

method _storeExterns [line 625]

void _storeExterns( )

Write the EXTERNCOUNT and EXTERNSHEET records. the NAME records.

Write the EXTERNCOUNT and EXTERNSHEET records. These are used as indexes for the NAME records.




Tags:

access:  private


[ Top ]

method _storeExternsheet [line 1116]

void _storeExternsheet( string $sheetname)

Writes the Excel BIFF EXTERNSHEET record. formulas. rows and columns.

Writes the Excel BIFF EXTERNSHEET record. These references are used by formulas. NAME record is required to define the print area and the repeat rows and columns. A similar method is used in Worksheet.php for a slightly different purpose.




Tags:

access:  private


Parameters:

string   $sheetname   Worksheet name

[ Top ]

method _storeNameLong [line 1208]

void _storeNameLong( integer $index, integer $type, integer $rowmin, integer $rowmax, integer $colmin, integer $colmax)

Store the NAME record in the long format that is used for storing the repeat rows and columns when both are specified. _storeNameShort() but we use a separate method to keep the code clean.

Store the NAME record in the long format that is used for storing the repeat rows and columns when both are specified. This shares a lot of code with _storeNameShort() but we use a separate method to keep the code clean. Code abstraction for reuse can be carried too far, and I should know. ;-)




Tags:

access:  private


Parameters:

integer   $index   Sheet index
integer   $type   Built-in name type
integer   $rowmin   Start row
integer   $rowmax   End row
integer   $colmin   Start colum
integer   $colmax   End column

[ Top ]

method _storeNames [line 641]

void _storeNames( )

Write the NAME record to define the print area and the repeat rows and cols.

Write the NAME record to define the print area and the repeat rows and cols.




Tags:

access:  private


[ Top ]

method _storeNameShort [line 1142]

void _storeNameShort( integer $index, integer $type, integer $rowmin, integer $rowmax, integer $colmin, integer $colmax)

Store the NAME record in the short format that is used for storing the print area, repeat rows only and repeat columns only.

Store the NAME record in the short format that is used for storing the print area, repeat rows only and repeat columns only.




Tags:

access:  private


Parameters:

integer   $index   Sheet index
integer   $type   Built-in name type
integer   $rowmin   Start row
integer   $rowmax   End row
integer   $colmin   Start colum
integer   $colmax   End column

[ Top ]

method _storeNumFormat [line 1040]

void _storeNumFormat( string $format, integer $ifmt)

Writes Excel FORMAT record for non "built-in" numerical formats.

Writes Excel FORMAT record for non "built-in" numerical formats.




Tags:

access:  private


Parameters:

string   $format   Custom format string
integer   $ifmt   Format index code

[ Top ]

method _storePalette [line 1318]

void _storePalette( )

Stores the PALETTE biff record.

Stores the PALETTE biff record.




Tags:

access:  private


[ Top ]

method _storeStyle [line 1018]

void _storeStyle( )

Write Excel BIFF STYLE records.

Write Excel BIFF STYLE records.




Tags:

access:  private


[ Top ]

method _storeWindow1 [line 912]

void _storeWindow1( )

Write Excel BIFF WINDOW1 record.

Write Excel BIFF WINDOW1 record.




Tags:

access:  private


[ Top ]

method _writeAllDefinedNamesBiff8 [line 734]

void _writeAllDefinedNamesBiff8( )

Writes all the DEFINEDNAME records (BIFF8).

Writes all the DEFINEDNAME records (BIFF8). So far this is only used for repeating rows/columns (print titles) and print areas




Tags:

access:  private


[ Top ]

method _writeCountry [line 1283]

string _writeCountry( )

Stores the COUNTRY record for localization

Stores the COUNTRY record for localization




Tags:

access:  private


[ Top ]

method _writeDefinedNameBiff8 [line 864]

string _writeDefinedNameBiff8( string $name, string $formulaData, [string $sheetIndex = 0], [boolean $isBuiltIn = false])

Write a DEFINEDNAME record for BIFF8 using explicit binary formula data

Write a DEFINEDNAME record for BIFF8 using explicit binary formula data




Tags:

return:  Complete binary record data
access:  private


Parameters:

string   $name   The name in UTF-8
string   $formulaData   The binary formula data
string   $sheetIndex   1-based sheet index the defined name applies to. 0 = global
boolean   $isBuiltIn   Built-in name?

[ Top ]

method _writeExternsheetBiff8 [line 998]

void _writeExternsheetBiff8( )

Writes the Excel BIFF EXTERNSHEET record. formulas.

Writes the Excel BIFF EXTERNSHEET record. These references are used by formulas.




Tags:

access:  private


[ Top ]

method _writeMsoDrawingGroup [line 1474]

void _writeMsoDrawingGroup( )

Writes the MSODRAWINGGROUP record if needed.

Writes the MSODRAWINGGROUP record if needed. Possibly split using CONTINUE records.




Tags:

access:  private


[ Top ]

method _writeRecalcId [line 1300]

string _writeRecalcId( )

Write the RECALCID record

Write the RECALCID record




Tags:

access:  private


[ Top ]

method _writeSharedStringsTable [line 1352]

string _writeSharedStringsTable( )

Handling of the SST continue blocks is complicated by the need to include an additional continuation byte depending on whether the string is split between blocks or whether it starts at the beginning of the block. additional complications that will arise later when/if Rich Strings are supported).

Handling of the SST continue blocks is complicated by the need to include an additional continuation byte depending on whether the string is split between blocks or whether it starts at the beginning of the block. (There are also additional complications that will arise later when/if Rich Strings are supported). The Excel documentation says that the SST record should be followed by an EXTSST record. The EXTSST record is a hash table that is used to optimise access to SST. However, despite the documentation it doesn't seem to be required so we will ignore it.




Tags:

return:  Binary data
access:  private


[ Top ]

method _writeSupbookInternal [line 983]

void _writeSupbookInternal( )

Write Internal SUPBOOK record

Write Internal SUPBOOK record




Tags:

access:  private


[ Top ]


Documentation generated on Mon, 11 Jan 2010 08:18:39 +0100 by phpDocumentor 1.4.1