Packages

  • Nette
    • Application
      • Diagnostics
      • Responses
      • Routers
      • UI
    • Caching
      • Storages
    • ComponentModel
    • Config
      • Adapters
      • Extensions
    • Database
      • Diagnostics
      • Drivers
      • Reflection
      • Table
    • DI
      • Diagnostics
    • Diagnostics
    • Forms
      • Controls
      • Rendering
    • Http
    • Iterators
    • Latte
      • Macros
    • Loaders
    • Localization
    • Mail
    • Reflection
    • Security
      • Diagnostics
    • Templating
    • Utils
      • PhpGenerator
  • NetteModule
  • None
  • PHP

Classes

  • Connection
  • DatabaseHelpers
  • Row
  • SqlLiteral
  • SqlPreprocessor
  • Statement

Interfaces

  • IReflection
  • ISupplementalDriver
  • Overview
  • Package
  • Class
  • Tree
  • Deprecated
 1: <?php
 2: 
 3: /**
 4:  * This file is part of the Nette Framework (http://nette.org)
 5:  *
 6:  * Copyright (c) 2004 David Grudl (http://davidgrudl.com)
 7:  *
 8:  * For the full copyright and license information, please view
 9:  * the file license.txt that was distributed with this source code.
10:  * @package Nette\Database
11:  */
12: 
13: 
14: 
15: /**
16:  * Information about tables and columns structure.
17:  * @package Nette\Database
18:  */
19: interface IReflection
20: {
21:     const
22:         FIELD_TEXT = 'string',
23:         FIELD_BINARY = 'bin',
24:         FIELD_BOOL = 'bool',
25:         FIELD_INTEGER = 'int',
26:         FIELD_FLOAT = 'float',
27:         FIELD_DATE = 'date',
28:         FIELD_TIME = 'time',
29:         FIELD_DATETIME = 'datetime';
30: 
31:     /**
32:      * Gets primary key of $table.
33:      * @param  string
34:      * @return string
35:      */
36:     function getPrimary($table);
37: 
38:     /**
39:      * Gets referenced table & referenced column.
40:      * Example:
41:      *   author, book returns array(book, author_id)
42:      *
43:      * @param  string  source table
44:      * @param  string  referencing key
45:      * @return array   array(referenced table, referenced column)
46:      * @throws MissingReferenceException
47:      * @throws AmbiguousReferenceKeyException
48:      */
49:     function getHasManyReference($table, $key);
50: 
51:     /**
52:      * Gets referenced table & referencing column.
53:      * Example
54:      *     book, author      returns array(author, author_id)
55:      *     book, translator  returns array(author, translator_id)
56:      *
57:      * @param  string  source table
58:      * @param  string  referencing key
59:      * @return array   array(referenced table, referencing column)
60:      * @throws MissingReferenceException
61:      */
62:     function getBelongsToReference($table, $key);
63: 
64:     /**
65:      * Injects database connection.
66:      */
67:     function setConnection(Connection $connection);
68: 
69: }
70: 
Nette Framework 2.0.13 (for PHP 5.2, un-prefixed) API API documentation generated by ApiGen 2.8.0