ILIAS  release_5-3 Revision v5.3.23-19-g915713cf615
PHPExcel_Worksheet_HeaderFooter Class Reference
+ Collaboration diagram for PHPExcel_Worksheet_HeaderFooter:

Public Member Functions

 __construct ()
 Create a new PHPExcel_Worksheet_HeaderFooter. More...
 
 getOddHeader ()
 Get OddHeader. More...
 
 setOddHeader ($pValue)
 Set OddHeader. More...
 
 getOddFooter ()
 Get OddFooter. More...
 
 setOddFooter ($pValue)
 Set OddFooter. More...
 
 getEvenHeader ()
 Get EvenHeader. More...
 
 setEvenHeader ($pValue)
 Set EvenHeader. More...
 
 getEvenFooter ()
 Get EvenFooter. More...
 
 setEvenFooter ($pValue)
 Set EvenFooter. More...
 
 getFirstHeader ()
 Get FirstHeader. More...
 
 setFirstHeader ($pValue)
 Set FirstHeader. More...
 
 getFirstFooter ()
 Get FirstFooter. More...
 
 setFirstFooter ($pValue)
 Set FirstFooter. More...
 
 getDifferentOddEven ()
 Get DifferentOddEven. More...
 
 setDifferentOddEven ($pValue=false)
 Set DifferentOddEven. More...
 
 getDifferentFirst ()
 Get DifferentFirst. More...
 
 setDifferentFirst ($pValue=false)
 Set DifferentFirst. More...
 
 getScaleWithDocument ()
 Get ScaleWithDocument. More...
 
 setScaleWithDocument ($pValue=true)
 Set ScaleWithDocument. More...
 
 getAlignWithMargins ()
 Get AlignWithMargins. More...
 
 setAlignWithMargins ($pValue=true)
 Set AlignWithMargins. More...
 
 addImage (PHPExcel_Worksheet_HeaderFooterDrawing $image=null, $location=self::IMAGE_HEADER_LEFT)
 Add header/footer image. More...
 
 removeImage ($location=self::IMAGE_HEADER_LEFT)
 Remove header/footer image. More...
 
 setImages ($images)
 Set header/footer images. More...
 
 getImages ()
 Get header/footer images. More...
 
 __clone ()
 Implement PHP __clone to create a deep clone, not just a shallow copy. More...
 

Data Fields

const IMAGE_HEADER_LEFT = 'LH'
 
const IMAGE_HEADER_CENTER = 'CH'
 
const IMAGE_HEADER_RIGHT = 'RH'
 
const IMAGE_FOOTER_LEFT = 'LF'
 
const IMAGE_FOOTER_CENTER = 'CF'
 
const IMAGE_FOOTER_RIGHT = 'RF'
 

Private Attributes

 $_oddHeader = ''
 
 $_oddFooter = ''
 
 $_evenHeader = ''
 
 $_evenFooter = ''
 
 $_firstHeader = ''
 
 $_firstFooter = ''
 
 $_differentOddEven = false
 
 $_differentFirst = false
 
 $_scaleWithDocument = true
 
 $_alignWithMargins = true
 
 $_headerFooterImages = array()
 

Detailed Description

Definition at line 96 of file HeaderFooter.php.

Constructor & Destructor Documentation

◆ __construct()

PHPExcel_Worksheet_HeaderFooter::__construct ( )

Create a new PHPExcel_Worksheet_HeaderFooter.

Definition at line 186 of file HeaderFooter.php.

187  {
188  }

Member Function Documentation

◆ __clone()

PHPExcel_Worksheet_HeaderFooter::__clone ( )

Implement PHP __clone to create a deep clone, not just a shallow copy.

Definition at line 455 of file HeaderFooter.php.

References $key.

455  {
456  $vars = get_object_vars($this);
457  foreach ($vars as $key => $value) {
458  if (is_object($value)) {
459  $this->$key = clone $value;
460  } else {
461  $this->$key = $value;
462  }
463  }
464  }
$key
Definition: croninfo.php:18

◆ addImage()

PHPExcel_Worksheet_HeaderFooter::addImage ( PHPExcel_Worksheet_HeaderFooterDrawing  $image = null,
  $location = self::IMAGE_HEADER_LEFT 
)

Add header/footer image.

Parameters
PHPExcel_Worksheet_HeaderFooterDrawing$image
string$location
Exceptions
PHPExcel_Exception
Returns
PHPExcel_Worksheet_HeaderFooter

Definition at line 398 of file HeaderFooter.php.

References $location.

398  {
399  $this->_headerFooterImages[$location] = $image;
400  return $this;
401  }
$location
Definition: buildRTE.php:44

◆ getAlignWithMargins()

PHPExcel_Worksheet_HeaderFooter::getAlignWithMargins ( )

Get AlignWithMargins.

Returns
boolean

Definition at line 375 of file HeaderFooter.php.

References $_alignWithMargins.

◆ getDifferentFirst()

PHPExcel_Worksheet_HeaderFooter::getDifferentFirst ( )

Get DifferentFirst.

Returns
boolean

Definition at line 335 of file HeaderFooter.php.

References $_differentFirst.

335  {
336  return $this->_differentFirst;
337  }

◆ getDifferentOddEven()

PHPExcel_Worksheet_HeaderFooter::getDifferentOddEven ( )

Get DifferentOddEven.

Returns
boolean

Definition at line 315 of file HeaderFooter.php.

References $_differentOddEven.

◆ getEvenFooter()

PHPExcel_Worksheet_HeaderFooter::getEvenFooter ( )

Get EvenFooter.

Returns
string

Definition at line 255 of file HeaderFooter.php.

References $_evenFooter.

255  {
256  return $this->_evenFooter;
257  }

◆ getEvenHeader()

PHPExcel_Worksheet_HeaderFooter::getEvenHeader ( )

Get EvenHeader.

Returns
string

Definition at line 235 of file HeaderFooter.php.

References $_evenHeader.

235  {
236  return $this->_evenHeader;
237  }

◆ getFirstFooter()

PHPExcel_Worksheet_HeaderFooter::getFirstFooter ( )

Get FirstFooter.

Returns
string

Definition at line 295 of file HeaderFooter.php.

References $_firstFooter.

295  {
296  return $this->_firstFooter;
297  }

◆ getFirstHeader()

PHPExcel_Worksheet_HeaderFooter::getFirstHeader ( )

Get FirstHeader.

Returns
string

Definition at line 275 of file HeaderFooter.php.

References $_firstHeader.

275  {
276  return $this->_firstHeader;
277  }

◆ getImages()

PHPExcel_Worksheet_HeaderFooter::getImages ( )

Get header/footer images.

Returns
PHPExcel_Worksheet_HeaderFooterDrawing[]

Definition at line 438 of file HeaderFooter.php.

References $_headerFooterImages, and array.

438  {
439  // Sort array
440  $images = array();
441  if (isset($this->_headerFooterImages[self::IMAGE_HEADER_LEFT])) $images[self::IMAGE_HEADER_LEFT] = $this->_headerFooterImages[self::IMAGE_HEADER_LEFT];
442  if (isset($this->_headerFooterImages[self::IMAGE_HEADER_CENTER])) $images[self::IMAGE_HEADER_CENTER] = $this->_headerFooterImages[self::IMAGE_HEADER_CENTER];
443  if (isset($this->_headerFooterImages[self::IMAGE_HEADER_RIGHT])) $images[self::IMAGE_HEADER_RIGHT] = $this->_headerFooterImages[self::IMAGE_HEADER_RIGHT];
444  if (isset($this->_headerFooterImages[self::IMAGE_FOOTER_LEFT])) $images[self::IMAGE_FOOTER_LEFT] = $this->_headerFooterImages[self::IMAGE_FOOTER_LEFT];
445  if (isset($this->_headerFooterImages[self::IMAGE_FOOTER_CENTER])) $images[self::IMAGE_FOOTER_CENTER] = $this->_headerFooterImages[self::IMAGE_FOOTER_CENTER];
446  if (isset($this->_headerFooterImages[self::IMAGE_FOOTER_RIGHT])) $images[self::IMAGE_FOOTER_RIGHT] = $this->_headerFooterImages[self::IMAGE_FOOTER_RIGHT];
447  $this->_headerFooterImages = $images;
448 
450  }
Create styles array
The data for the language used.

◆ getOddFooter()

PHPExcel_Worksheet_HeaderFooter::getOddFooter ( )

Get OddFooter.

Returns
string

Definition at line 215 of file HeaderFooter.php.

References $_oddFooter.

215  {
216  return $this->_oddFooter;
217  }

◆ getOddHeader()

PHPExcel_Worksheet_HeaderFooter::getOddHeader ( )

Get OddHeader.

Returns
string

Definition at line 195 of file HeaderFooter.php.

References $_oddHeader.

195  {
196  return $this->_oddHeader;
197  }

◆ getScaleWithDocument()

PHPExcel_Worksheet_HeaderFooter::getScaleWithDocument ( )

Get ScaleWithDocument.

Returns
boolean

Definition at line 355 of file HeaderFooter.php.

References $_scaleWithDocument.

◆ removeImage()

PHPExcel_Worksheet_HeaderFooter::removeImage (   $location = self::IMAGE_HEADER_LEFT)

Remove header/footer image.

Parameters
string$location
Exceptions
PHPExcel_Exception
Returns
PHPExcel_Worksheet_HeaderFooter

Definition at line 410 of file HeaderFooter.php.

References $location.

410  {
411  if (isset($this->_headerFooterImages[$location])) {
412  unset($this->_headerFooterImages[$location]);
413  }
414  return $this;
415  }
$location
Definition: buildRTE.php:44

◆ setAlignWithMargins()

PHPExcel_Worksheet_HeaderFooter::setAlignWithMargins (   $pValue = true)

Set AlignWithMargins.

Parameters
boolean$pValue
Returns
PHPExcel_Worksheet_HeaderFooter

Definition at line 385 of file HeaderFooter.php.

385  {
386  $this->_alignWithMargins = $pValue;
387  return $this;
388  }

◆ setDifferentFirst()

PHPExcel_Worksheet_HeaderFooter::setDifferentFirst (   $pValue = false)

Set DifferentFirst.

Parameters
boolean$pValue
Returns
PHPExcel_Worksheet_HeaderFooter

Definition at line 345 of file HeaderFooter.php.

345  {
346  $this->_differentFirst = $pValue;
347  return $this;
348  }

◆ setDifferentOddEven()

PHPExcel_Worksheet_HeaderFooter::setDifferentOddEven (   $pValue = false)

Set DifferentOddEven.

Parameters
boolean$pValue
Returns
PHPExcel_Worksheet_HeaderFooter

Definition at line 325 of file HeaderFooter.php.

325  {
326  $this->_differentOddEven = $pValue;
327  return $this;
328  }

◆ setEvenFooter()

PHPExcel_Worksheet_HeaderFooter::setEvenFooter (   $pValue)

Set EvenFooter.

Parameters
string$pValue
Returns
PHPExcel_Worksheet_HeaderFooter

Definition at line 265 of file HeaderFooter.php.

265  {
266  $this->_evenFooter = $pValue;
267  return $this;
268  }

◆ setEvenHeader()

PHPExcel_Worksheet_HeaderFooter::setEvenHeader (   $pValue)

Set EvenHeader.

Parameters
string$pValue
Returns
PHPExcel_Worksheet_HeaderFooter

Definition at line 245 of file HeaderFooter.php.

245  {
246  $this->_evenHeader = $pValue;
247  return $this;
248  }

◆ setFirstFooter()

PHPExcel_Worksheet_HeaderFooter::setFirstFooter (   $pValue)

Set FirstFooter.

Parameters
string$pValue
Returns
PHPExcel_Worksheet_HeaderFooter

Definition at line 305 of file HeaderFooter.php.

305  {
306  $this->_firstFooter = $pValue;
307  return $this;
308  }

◆ setFirstHeader()

PHPExcel_Worksheet_HeaderFooter::setFirstHeader (   $pValue)

Set FirstHeader.

Parameters
string$pValue
Returns
PHPExcel_Worksheet_HeaderFooter

Definition at line 285 of file HeaderFooter.php.

285  {
286  $this->_firstHeader = $pValue;
287  return $this;
288  }

◆ setImages()

PHPExcel_Worksheet_HeaderFooter::setImages (   $images)

Set header/footer images.

Parameters
PHPExcel_Worksheet_HeaderFooterDrawing[]$images
Exceptions
PHPExcel_Exception
Returns
PHPExcel_Worksheet_HeaderFooter

Definition at line 424 of file HeaderFooter.php.

424  {
425  if (!is_array($images)) {
426  throw new PHPExcel_Exception('Invalid parameter!');
427  }
428 
429  $this->_headerFooterImages = $images;
430  return $this;
431  }

◆ setOddFooter()

PHPExcel_Worksheet_HeaderFooter::setOddFooter (   $pValue)

Set OddFooter.

Parameters
string$pValue
Returns
PHPExcel_Worksheet_HeaderFooter

Definition at line 225 of file HeaderFooter.php.

225  {
226  $this->_oddFooter = $pValue;
227  return $this;
228  }

◆ setOddHeader()

PHPExcel_Worksheet_HeaderFooter::setOddHeader (   $pValue)

Set OddHeader.

Parameters
string$pValue
Returns
PHPExcel_Worksheet_HeaderFooter

Definition at line 205 of file HeaderFooter.php.

205  {
206  $this->_oddHeader = $pValue;
207  return $this;
208  }

◆ setScaleWithDocument()

PHPExcel_Worksheet_HeaderFooter::setScaleWithDocument (   $pValue = true)

Set ScaleWithDocument.

Parameters
boolean$pValue
Returns
PHPExcel_Worksheet_HeaderFooter

Definition at line 365 of file HeaderFooter.php.

365  {
366  $this->_scaleWithDocument = $pValue;
367  return $this;
368  }

Field Documentation

◆ $_alignWithMargins

PHPExcel_Worksheet_HeaderFooter::$_alignWithMargins = true
private

Definition at line 174 of file HeaderFooter.php.

Referenced by getAlignWithMargins().

◆ $_differentFirst

PHPExcel_Worksheet_HeaderFooter::$_differentFirst = false
private

Definition at line 160 of file HeaderFooter.php.

Referenced by getDifferentFirst().

◆ $_differentOddEven

PHPExcel_Worksheet_HeaderFooter::$_differentOddEven = false
private

Definition at line 153 of file HeaderFooter.php.

Referenced by getDifferentOddEven().

◆ $_evenFooter

PHPExcel_Worksheet_HeaderFooter::$_evenFooter = ''
private

Definition at line 132 of file HeaderFooter.php.

Referenced by getEvenFooter().

◆ $_evenHeader

PHPExcel_Worksheet_HeaderFooter::$_evenHeader = ''
private

Definition at line 125 of file HeaderFooter.php.

Referenced by getEvenHeader().

◆ $_firstFooter

PHPExcel_Worksheet_HeaderFooter::$_firstFooter = ''
private

Definition at line 146 of file HeaderFooter.php.

Referenced by getFirstFooter().

◆ $_firstHeader

PHPExcel_Worksheet_HeaderFooter::$_firstHeader = ''
private

Definition at line 139 of file HeaderFooter.php.

Referenced by getFirstHeader().

◆ $_headerFooterImages

PHPExcel_Worksheet_HeaderFooter::$_headerFooterImages = array()
private

Definition at line 181 of file HeaderFooter.php.

Referenced by getImages().

◆ $_oddFooter

PHPExcel_Worksheet_HeaderFooter::$_oddFooter = ''
private

Definition at line 118 of file HeaderFooter.php.

Referenced by getOddFooter().

◆ $_oddHeader

PHPExcel_Worksheet_HeaderFooter::$_oddHeader = ''
private

Definition at line 111 of file HeaderFooter.php.

Referenced by getOddHeader().

◆ $_scaleWithDocument

PHPExcel_Worksheet_HeaderFooter::$_scaleWithDocument = true
private

Definition at line 167 of file HeaderFooter.php.

Referenced by getScaleWithDocument().

◆ IMAGE_FOOTER_CENTER

const PHPExcel_Worksheet_HeaderFooter::IMAGE_FOOTER_CENTER = 'CF'

Definition at line 103 of file HeaderFooter.php.

◆ IMAGE_FOOTER_LEFT

const PHPExcel_Worksheet_HeaderFooter::IMAGE_FOOTER_LEFT = 'LF'

Definition at line 102 of file HeaderFooter.php.

◆ IMAGE_FOOTER_RIGHT

const PHPExcel_Worksheet_HeaderFooter::IMAGE_FOOTER_RIGHT = 'RF'

Definition at line 104 of file HeaderFooter.php.

◆ IMAGE_HEADER_CENTER

const PHPExcel_Worksheet_HeaderFooter::IMAGE_HEADER_CENTER = 'CH'

Definition at line 100 of file HeaderFooter.php.

◆ IMAGE_HEADER_LEFT

const PHPExcel_Worksheet_HeaderFooter::IMAGE_HEADER_LEFT = 'LH'

Definition at line 99 of file HeaderFooter.php.

◆ IMAGE_HEADER_RIGHT

const PHPExcel_Worksheet_HeaderFooter::IMAGE_HEADER_RIGHT = 'RH'

Definition at line 101 of file HeaderFooter.php.


The documentation for this class was generated from the following file: