Propel API
Class

PropelFormatter

abstract class PropelFormatter

Abstract class for query formatter

Methods

__construct(ModelCriteria $criteria = null)

PropelFormatter init(ModelCriteria $criteria)

Define the hydration schema based on a query object.

setDbName($dbName)

getDbName()

setClass($class)

getClass()

setPeer($peer)

getPeer()

setWith($withs = array())

getWith()

setAsColumns($asColumns = array())

getAsColumns()

setHasLimit($hasLimit = false)

hasLimit()

BaseObject formatRecord(BaseObject $record = null)

Formats an ActiveRecord object

format(PDOStatement $stmt)

formatOne(PDOStatement $stmt)

isObjectFormatter()

checkInit()

getTableMap()

BaseObject getSingleObjectFromRow(array $row, string $class, int $col)

Gets a Propel object hydrated from a selection of columns in statement row

Details

at line 29
public __construct(ModelCriteria $criteria = null)

Parameters

ModelCriteria $criteria

at line 44
public PropelFormatter init(ModelCriteria $criteria)

Define the hydration schema based on a query object.

Fills the Formatter's properties using a Criteria as source

Parameters

ModelCriteria $criteria

Return Value

PropelFormatter The current formatter object

at line 57
public setDbName($dbName)

Parameters

$dbName

at line 62
public getDbName()

at line 67
public setClass($class)

Parameters

$class

at line 73
public getClass()

at line 78
public setPeer($peer)

Parameters

$peer

at line 83
public getPeer()

at line 88
public setWith($withs = array())

Parameters

$withs

at line 93
public getWith()

at line 98
public setAsColumns($asColumns = array())

Parameters

$asColumns

at line 103
public getAsColumns()

at line 108
public setHasLimit($hasLimit = false)

Parameters

$hasLimit

at line 113
public hasLimit()

at line 125
public BaseObject formatRecord(BaseObject $record = null)

Formats an ActiveRecord object

Parameters

BaseObject $record the object to format

Return Value

BaseObject The original record

at line 130
abstract public format(PDOStatement $stmt)

Parameters

PDOStatement $stmt

at line 132
abstract public formatOne(PDOStatement $stmt)

Parameters

PDOStatement $stmt

at line 134
abstract public isObjectFormatter()

at line 136
public checkInit()

at line 143
public getTableMap()

at line 192
public BaseObject getSingleObjectFromRow(array $row, string $class, int $col)

Gets a Propel object hydrated from a selection of columns in statement row

Parameters

array $row associative array indexed by column number, as returned by PDOStatement::fetch(PDO::FETCH_NUM)
string $class The classname of the object to create
int $col The start column for the hydration (modified)

Return Value

BaseObject