Bluz\Db\Row

Db Table Row

Example of Users\Row
<code>
namespace Application\Users;
class Row extends \Bluz\Db\Row
{
public function beforeInsert()
{
$this->created = gmdate('Y-m-d H:i:s');
}

public function beforeUpdate()
{
$this->updated = gmdate('Y-m-d H:i:s');
}
}

$userRow = new \Application\Users\Row();
$userRow -> login = 'username';
$userRow -> save();
</code>

Synopsis

class Row implements JsonSerializable,ArrayAccess {
  • // Inherited methods from JsonSerialize
  • public array jsonSerialize()
  • // Inherited methods from MagicAccess
  • public void __set()
  • public mixed __get()
  • public bool __isset()
  • public void __unset()
}

Hierarchy

Violations

PHPMessDetector

Line Rule Message
136 UnusedFormalParameter Avoid unused parameters such as '$data'.
147 UnusedFormalParameter Avoid unused parameters such as '$data'.

Members

protected

  • $clean — array
    This is set to a copy of $data when the data is fetched from a database, specified as a new tuple in the constructor, or when dirty data is posted to the database with save().
  • $container — array
  • $relations — array
  • $tableBluz\Db\Table
  • $tableClass — string

Methods

protected

public

Inherited from Bluz\Common\Container\Container

protected

public

Inherited from Bluz\Common\Container\ArrayAccess

public

Inherited from Bluz\Common\Container\JsonSerialize

public

Inherited from Bluz\Common\Container\MagicAccess

public

  • __get() — Magic alias for get() regular method
  • __isset() — Magic alias for contains() regular method
  • __set() — Magic alias for set() regular method
  • __unset() — Magic alias for delete() regular method

History