Overview

Namespaces

  • DSchoenbauer
    • Orm
      • Builder
      • Entity
      • Enum
      • Events
        • Persistence
        • Validate
          • DataType
          • Schema
      • Exception
      • Framework

Classes

  • CrudModel
  • Model

Interfaces

  • VisitorInterface
  • Overview
  • Namespace
  • Class

Class CrudModel

Extends core model adding a basic set of methods triggering key events for crud operations

DSchoenbauer\Orm\Model uses Zend\EventManager\EventManagerAwareTrait (not available)
Extended by DSchoenbauer\Orm\CrudModel
Namespace: DSchoenbauer\Orm
Author: David Schoenbauer
Located at Orm/CrudModel.php
Methods summary
public array
# create( array $data )

Process the addition of a new record

Process the addition of a new record

Parameters

$data

Returns

array

Since

v1.0.0
public array
# fetch( integer $id )

Process the return of a single record

Process the return of a single record

Parameters

$id

Returns

array

Since

v1.0.0
public array
# fetchAll( )

Process the return of a collection of data

Process the return of a collection of data

Returns

array

Since

v1.0.0
public array
# update( integer $id, array $data )

Process the update of data for a given id

Process the update of data for a given id

Parameters

$id
primary id number of the record to be updated
$data
an associative array of the data to be updated

Returns

array

Since

v1.0.0
public boolean
# delete( integer $id )

Process the removal of a given record

Process the removal of a given record

Parameters

$id
primary ID of a value to be removed

Returns

boolean
returns true on success

Since

v1.0.0
Methods inherited from DSchoenbauer\Orm\Model
__construct(), accept(), getAttributes(), getData(), getEntity(), getId(), setAttributes(), setData(), setEntity(), setId()
API documentation generated by ApiGen