noalyss Version-9
Public Member Functions | Private Attributes
Export_Data_PDF Class Reference
+ Inheritance diagram for Export_Data_PDF:
+ Collaboration diagram for Export_Data_PDF:

Public Member Functions

 __construct ($p_result, $paColum_name,\PDF_Core $pdf)
 
 export ($p_destination_file)
 
 table_header ()
 
- Public Member Functions inherited from Export_Data
 __construct ($p_result, $paColum_name)
 
 export ($p_destination_file)
 
 get_aColumn_name ()
 
 get_db_handler ()
 
 set_aColumn_name ($aColumn_name)
 
 set_db_handler ($db_handler)
 

Private Attributes

 $aSize
 double array : key column name, value size of the column More...
 
 $pdf
 

Detailed Description

Definition at line 23 of file export_data_pdf.class.php.

Constructor & Destructor Documentation

◆ __construct()

Export_Data_PDF::__construct (   $p_result,
  $paColum_name,
\PDF_Core  $pdf 
)

Definition at line 27 of file export_data_pdf.class.php.

28 {
29 parent::__construct($p_result,$paColum_name);
30 $this->pdf=$pdf;
31
32 // compute the size of column
34 if ( $this->pdf->get_orientation() == 'P'){
35 $pagesize=210-$this->pdf->get_margin_left()-$this->pdf->get_margin_right();
36 } else {
37 $pagesize=297-$this->pdf->get_margin_left()-$this->pdf->get_margin_right();
38 }
39 $width=$pagesize/$nb_col;
40 $aColumnName=$this->get_aColumn_name();
41 $nb_column_name=count($aColumnName);
42 $aKey=array_keys($aColumnName);
43
44 for ($i=0;$i<count($aColumnName);$i++)
45 {
46 $name=$aKey[$i];
47 $this->aSize[$name]=$width;
48 }
49
50 }
static nb_column($p_ret)
Returns the number of columns in a ret.
$width

References $i, $name, $nb_col, $pdf, $width, Export_Data\get_aColumn_name(), Export_Data\get_db_handler(), and DatabaseCore\nb_column().

+ Here is the call graph for this function:

Member Function Documentation

◆ export()

Export_Data_PDF::export (   $p_destination_file)

Reimplemented from Export_Data.

Definition at line 55 of file export_data_pdf.class.php.

56 {
57 $handler=$this->get_db_handler();
59 $this->table_header();
60 for ($i=0;$i<$nb_row;$i++)
61 {
62
63 }
64 }
static num_row($ret)
wrapper for the function pg_num_rows

References $i, $nb_row, Export_Data\get_db_handler(), DatabaseCore\num_row(), and table_header().

+ Here is the call graph for this function:

◆ table_header()

Export_Data_PDF::table_header ( )

Definition at line 51 of file export_data_pdf.class.php.

52 {
53
54 }

Referenced by export().

Field Documentation

◆ $aSize

Export_Data_PDF::$aSize
private

double array : key column name, value size of the column

Definition at line 26 of file export_data_pdf.class.php.

◆ $pdf

Export_Data_PDF::$pdf
private

Definition at line 25 of file export_data_pdf.class.php.

Referenced by __construct().


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