PHP Class Bravo3\Orm\Query\SortedQuery

Inheritance: extends AbstractQuery, implements Bravo3\Orm\Query\QueryInterface
Datei anzeigen Open project: bravo3/orm Class Usage Examples

Protected Properties

Property Type Description
$direction Bravo3\Orm\Enum\Direction
$end integer
$entity object
$relationship_name string
$sort_by string
$start integer

Public Methods

Method Description
__construct ( object $entity, string $relationship_name, string $sort_by, Direction $direction = null, integer $start = null, integer $end = null )
getDirection ( ) : Direction Get Direction
getEnd ( ) : integer Get end index
getEntity ( ) : object Get Entity
getRelationshipName ( ) : string Get relationship name
getSortBy ( ) : string Get sorting field name
getStart ( ) : integer Get start index
setDirection ( Direction $direction ) Set Direction
setEnd ( integer $end ) Set end index
setEntity ( object $entity ) Set Entity
setRelationshipName ( string $relationship_name ) Set relationship name
setSortBy ( string $sort_by ) Set sorting field name
setStart ( integer $start ) Set start index

Method Details

__construct() public method

public __construct ( object $entity, string $relationship_name, string $sort_by, Direction $direction = null, integer $start = null, integer $end = null )
$entity object Entity to retrieve relationships from
$relationship_name string Name of the relationship on provided entity
$sort_by string Sort by column
$direction Bravo3\Orm\Enum\Direction Assumes ascending if omitted
$start integer Start index (inclusive), null/0 for beginning of set
$end integer Stop index (inclusive), null/-1 for end of set, -2 for penultimate record

getDirection() public method

Get Direction
public getDirection ( ) : Direction
return Bravo3\Orm\Enum\Direction

getEnd() public method

Get end index
public getEnd ( ) : integer
return integer

getEntity() public method

Get Entity
public getEntity ( ) : object
return object

getRelationshipName() public method

Get relationship name
public getRelationshipName ( ) : string
return string

getSortBy() public method

Get sorting field name
public getSortBy ( ) : string
return string

getStart() public method

Get start index
public getStart ( ) : integer
return integer

setDirection() public method

Set Direction
public setDirection ( Direction $direction )
$direction Bravo3\Orm\Enum\Direction

setEnd() public method

Set end index
public setEnd ( integer $end )
$end integer

setEntity() public method

Set Entity
public setEntity ( object $entity )
$entity object

setRelationshipName() public method

Set relationship name
public setRelationshipName ( string $relationship_name )
$relationship_name string

setSortBy() public method

Set sorting field name
public setSortBy ( string $sort_by )
$sort_by string

setStart() public method

Set start index
public setStart ( integer $start )
$start integer

Property Details

$direction protected_oe property

protected Direction,Bravo3\Orm\Enum $direction
return Bravo3\Orm\Enum\Direction

$end protected_oe property

protected int $end
return integer

$entity protected_oe property

protected object $entity
return object

$relationship_name protected_oe property

protected string $relationship_name
return string

$sort_by protected_oe property

protected string $sort_by
return string

$start protected_oe property

protected int $start
return integer