Overview

Packages

  • Onion::Controllers
  • Onion::Core
  • Onion::UI
  • Onion::Utils

Classes

  • Authenticator
  • Controller
  • Database
  • DatabaseResult
  • Log
  • Model
  • Onion
  • Request
  • Response
  • User
  • Overview
  • Package
  • Class
  • Tree

Class Model

Onion Framework - Generický model

Copyright (c) 2011 Jano Gašpar (http://webstranky.net)

Model implements Iterator, Countable, ArrayAccess
Package: Onion::Core
Copyright: Copyright (c) 2011 Jano Gašpar
Author: Jano Gašpar
Located at Core/Model.php
Methods summary
public static object
# create( string $table, array $where = NULL )
Továrnička

Továrnička

Parameters

$table
string
názov tabuľky s modelmi
$where
array
pole s podmienkami na výber dát modelu

Returns

object
public static
# load( $table, $where )
public
# data( $data = NULL, $merge = FALSE )
public boolean|integer
# save( )
Uloženie modelu

Uloženie modelu

Returns

boolean|integer
FALSE alebo ID modelu
public
# delete( )
final public mixed &
# __get( string $property )
Metóda na vrátenie hodnoty vlastnosti modelu

Metóda na vrátenie hodnoty vlastnosti modelu

Parameters

$property
string
meno vlastnosti

Returns

mixed
hodnota vlastnosti
final public
# __set( string $property, $value )
Metóda na nastavenie hodnoty vlastnosti modelu

Metóda na nastavenie hodnoty vlastnosti modelu

Parameters

$property
string
meno vlastnosti
$value
public
# rewind( )
Rewinds the iterator to the first element.

Rewinds the iterator to the first element.

Implementation of

Iterator::rewind
public mixed
# key( )
Returns the key of the current element.

Returns the key of the current element.

Returns

mixed

Implementation of

Iterator::key
public mixed
# current( )
Returns the current element.

Returns the current element.

Returns

mixed

Implementation of

Iterator::current
public
# next( )
Moves forward to next element.

Moves forward to next element.

Implementation of

Iterator::next
public boolean
# valid( )
Checks if there is a current element after calls to rewind() or next().

Checks if there is a current element after calls to rewind() or next().

Returns

boolean

Implementation of

Iterator::valid
public integer
# count( )
Required by the Countable interface.

Required by the Countable interface.

Returns

integer

Implementation of

Countable::count
public
# offsetSet( $pointer, $value )

Implementation of

ArrayAccess::offsetSet
public
# offsetExists( $pointer )

Implementation of

ArrayAccess::offsetExists
public
# offsetUnset( $pointer )

Implementation of

ArrayAccess::offsetUnset
public
# offsetGet( $pointer )

Implementation of

ArrayAccess::offsetGet
Properties summary
private object $db
#
private string $table
#
private array $data array()
#
private integer $pointer
#
Onion API documentation generated by ApiGen.
Generated using the TokenReflection library.