PHP Class Pop\Data\Data

Author: Nick Sagona, III ([email protected])
Mostrar archivo Open project: nicksagona/PopPHP Class Usage Examples

Protected Properties

Property Type Description
$data string Data stream
$file string Data file stream
$idQuote string Data identifier quote
$pma boolean PMA compatible XML flag
$table string Data table
$type string Data file type

Public Methods

Method Description
__construct ( string $data ) : Data Constructor
factory ( string $data ) : Data Static method to instantiate the data object and return itself to facilitate chaining methods together.
getData ( ) : string Get the data stream
getFile ( ) : string Get the file stream
getIdQuote ( ) : string Get the ID quote
getPma ( ) : boolean Get the PMA flag
getTable ( ) : string Get the table name
parseData ( string $to, array $options = null ) : mixed Parse the data stream and return a file data stream.
parseFile ( ) : mixed Parse the data file stream and return a PHP data object.
setIdQuote ( string $quote ) : Data Set the identifier quote
setPma ( boolean $comp ) : Data Set the PMA compatible XML flag
setTable ( string $table ) : Data Set the table name
writeData ( string $toFile, boolean $output = false, boolean $download = false ) : Data Write the data stream to a file and either save or output it

Method Details

__construct() public method

Instantiate the data object.
public __construct ( string $data ) : Data
$data string
return Data

factory() public static method

Static method to instantiate the data object and return itself to facilitate chaining methods together.
public static factory ( string $data ) : Data
$data string
return Data

getData() public method

Get the data stream
public getData ( ) : string
return string

getFile() public method

Get the file stream
public getFile ( ) : string
return string

getIdQuote() public method

Get the ID quote
public getIdQuote ( ) : string
return string

getPma() public method

Get the PMA flag
public getPma ( ) : boolean
return boolean

getTable() public method

Get the table name
public getTable ( ) : string
return string

parseData() public method

Parse the data stream and return a file data stream.
public parseData ( string $to, array $options = null ) : mixed
$to string
$options array
return mixed

parseFile() public method

Parse the data file stream and return a PHP data object.
public parseFile ( ) : mixed
return mixed

setIdQuote() public method

Set the identifier quote
public setIdQuote ( string $quote ) : Data
$quote string
return Data

setPma() public method

Set the PMA compatible XML flag
public setPma ( boolean $comp ) : Data
$comp boolean
return Data

setTable() public method

Set the table name
public setTable ( string $table ) : Data
$table string
return Data

writeData() public method

Write the data stream to a file and either save or output it
public writeData ( string $toFile, boolean $output = false, boolean $download = false ) : Data
$toFile string
$output boolean
$download boolean
return Data

Property Details

$data protected_oe property

Data stream
protected string $data
return string

$file protected_oe property

Data file stream
protected string $file
return string

$idQuote protected_oe property

Data identifier quote
protected string $idQuote
return string

$pma protected_oe property

PMA compatible XML flag
protected bool $pma
return boolean

$table protected_oe property

Data table
protected string $table
return string

$type protected_oe property

Data file type
protected string $type
return string