class PdfRelationSchema extends ExportRelationSchema (View source)

Pdf Relation Schema Class

Purpose of this class is to generate the PDF Document. PDF is widely used format for documenting text,fonts,images and 3d vector graphics.

This class inherits ExportRelationSchema class has common functionality added to this class

Properties

protected string $db from  ExportRelationSchema
Pdf $diagram
protected bool $showColor from  ExportRelationSchema
protected bool $tableDimension from  ExportRelationSchema
protected bool $sameWide from  ExportRelationSchema
protected bool $showKeys from  ExportRelationSchema
protected string $orientation from  ExportRelationSchema
protected string $paper from  ExportRelationSchema
protected int $pageNumber from  ExportRelationSchema
protected bool $offline from  ExportRelationSchema
protected Relation $relation from  ExportRelationSchema
protected RelationStatsPdf[] $relations

Methods

__construct(string $db)

No description

void
setPageNumber(int $value)

Set Page Number

int
getPageNumber()

Returns the schema page number

void
setShowColor(bool $value)

Sets showColor

bool
isShowColor()

Returns whether to show colors

void
setTableDimension(bool $value)

Set Table Dimension

bool
isTableDimension()

Returns whether to show table dimensions

void
setAllTablesSameWidth(bool $value)

Set same width of All Tables

bool
isAllTableSameWidth()

Returns whether to use same width for all tables or not

void
setShowKeys(bool $value)

Set Show only keys

bool
isShowKeys()

Returns whether to show keys

void
setOrientation(string $value)

Set Orientation

string
getOrientation()

Returns orientation

void
setPaper(string $value)

Set type of paper

string
getPaper()

Returns the paper size

void
setOffline(bool $value)

Set whether the document is generated from client side DB

bool
isOffline()

Returns whether the client side database is used

array
getTablesFromRequest()

Get the table names from the request

string
getFileName(string $extension)

Returns the file name

static void
dieSchema(int $pageNumber, string $type = '', string $error_message = '')

Displays an error message

void
setShowGrid(bool $value)

Set Show Grid

bool
isShowGrid()

Returns whether to show grid

void
setWithDataDictionary(bool $value)

Set Data Dictionary

bool
isWithDataDictionary()

Return whether to show selected database data dictionary or not

void
setTableOrder(string $value)

Sets the order of the table in data dictionary

string
getTableOrder()

Returns the order of the table in data dictionary

void
showOutput()

Output Pdf Document for download

void
dataDictionaryDoc(array $alltables)

Generates data dictionary pages.

Details

__construct(string $db)

No description

Parameters

string $db

database name

See also

Pdf

void setPageNumber(int $value)

Set Page Number

Parameters

int $value

Page Number of the document to be created

Return Value

void

int getPageNumber()

Returns the schema page number

Return Value

int

schema page number

void setShowColor(bool $value)

Sets showColor

Parameters

bool $value

whether to show colors

Return Value

void

bool isShowColor()

Returns whether to show colors

Return Value

bool

void setTableDimension(bool $value)

Set Table Dimension

Parameters

bool $value

show table co-ordinates or not

Return Value

void

bool isTableDimension()

Returns whether to show table dimensions

Return Value

bool

void setAllTablesSameWidth(bool $value)

Set same width of All Tables

Parameters

bool $value

set same width of all tables or not

Return Value

void

bool isAllTableSameWidth()

Returns whether to use same width for all tables or not

Return Value

bool

void setShowKeys(bool $value)

Set Show only keys

Parameters

bool $value

show only keys or not

Return Value

void

bool isShowKeys()

Returns whether to show keys

Return Value

bool

void setOrientation(string $value)

Set Orientation

Parameters

string $value

Orientation will be portrait or landscape

Return Value

void

string getOrientation()

Returns orientation

Return Value

string orientation

void setPaper(string $value)

Set type of paper

Parameters

string $value

paper type can be A4 etc

Return Value

void

string getPaper()

Returns the paper size

Return Value

string

paper size

void setOffline(bool $value)

Set whether the document is generated from client side DB

Parameters

bool $value

offline or not

Return Value

void

bool isOffline()

Returns whether the client side database is used

Return Value

bool

protected array getTablesFromRequest()

Get the table names from the request

Return Value

array

an array of table names

protected string getFileName(string $extension)

Returns the file name

Parameters

string $extension

file extension

Return Value

string

file name

static void dieSchema(int $pageNumber, string $type = '', string $error_message = '')

Displays an error message

Parameters

int $pageNumber

ID of the chosen page

string $type

Schema Type

string $error_message

The error message

Return Value

void

void setShowGrid(bool $value)

Set Show Grid

Parameters

bool $value

show grid of the document or not

Return Value

void

bool isShowGrid()

Returns whether to show grid

Return Value

bool

void setWithDataDictionary(bool $value)

Set Data Dictionary

Parameters

bool $value

show selected database data dictionary or not

Return Value

void

bool isWithDataDictionary()

Return whether to show selected database data dictionary or not

Return Value

bool

void setTableOrder(string $value)

Sets the order of the table in data dictionary

Parameters

string $value

table order

Return Value

void

string getTableOrder()

Returns the order of the table in data dictionary

Return Value

string

table order

void showOutput()

Output Pdf Document for download

Return Value

void

void dataDictionaryDoc(array $alltables)

Generates data dictionary pages.

Parameters

array $alltables

Tables to document.

Return Value

void