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

  • NConnection
  • NDatabaseHelpers
  • NRow
  • NSqlLiteral
  • NSqlPreprocessor
  • NStatement

Interfaces

  • IReflection
  • ISupplementalDriver
  • Overview
  • Package
  • Class
  • Tree
 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:      */
47:     function getHasManyReference($table, $key);
48: 
49:     /**
50:      * Gets referenced table & referencing column
51:      * Example
52:      *     book, author      returns array(author, author_id)
53:      *     book, translator  returns array(author, translator_id)
54:      *
55:      * @param  string  source table
56:      * @param  string  referencing key
57:      * @return array   array(referenced table, referencing column)
58:      */
59:     function getBelongsToReference($table, $key);
60: 
61:     /**
62:      * Injects database connection.
63:      * @param  NConnection
64:      */
65:     function setConnection(NConnection $connection);
66: 
67: }
68: 
Nette Framework 2.0.1 (for PHP 5.2, prefixed) API API documentation generated by ApiGen 2.7.0