Class IBDatabase

(line 38)

Description

Object
   |
   --Persistent
      |
      --Component
         |
         --CustomConnection
            |
            --IBDatabase

Located in File: /interbase.inc.php

IBDatabase provides discrete control over a connection to a single InterBase database in a database application.

Use IBDatabase to specify the connection information so IBDataset components can connect to the database.



Properties

Summary:
Charset
DatabaseName Specifies the name of the database to associate with this database component.
Debug Sets the debug information provided by the component.
Dialect Specifies the dialect to be used when connecting to the server
Dictionary Specifies the tablename on this database that holds dictionary information
Host This properties specifies where to find the server to connect to.
UserName The username you want to use to connect to the database server.
UserPassword The password for the username you want to use to connect to the database server.
Connected Determines whether a connection has been established to the remote source of data. [Publishes CustomConnection::Connected]
DictionaryProperties Array containing all the information in array format about the dictionary

Defined in class CustomConnection

Clients Returns the clients of this database
Connected Determines whether a connection has been established to the remote source of data.
DataSets Provides an indexed array of all active datasets for a database component.

Defined in class Component

Name Specifies the name for the component. The name is used as an identifier and should be unique.
Tag A versatile property of every Component that can be used in any way you want
ComponentCount Indicates the number of components owned by the component.
Components Lists all the components owned by this component.
ControlState A flag to know the state of the control, csLoading, csDesigning
DataFieldValue This property returns the value of the datafield if any.
NamePath Specifies the path to uniquely identify a component, qualified by the owner when required.
Owner Indicates the component that is responsible for streaming and freeing this component.

Defined in class Persistent

NamePath Used to serialize/unserialize. It returns the full path to identify this component.
Owner Owner of the component.

property Charset (line 178)

void Charset


property DatabaseName (line 116)

string DatabaseName

Specifies the name of the database to associate with this database component.

Use DatabaseName to specify the name of the database to use with a database component.

Note: Setting DatabaseName when the Connected property is true requires you to close and reopen the database.


property Debug (line 90)

boolean Debug

Sets the debug information provided by the component.

Use this property, when set to true, to get more information about the connection process to address any issue you get.


property Dialect (line 172)

string Dialect

Specifies the dialect to be used when connecting to the server

Reserved for future use.


property Dictionary (line 103)

string Dictionary

Specifies the tablename on this database that holds dictionary information

A dictionary is a set of information about each field of each table, which data-aware components use to show information about the table in a human-readable format, for example, the title for each field, the width for a column, etc


property Host (line 126)

string Host

This properties specifies where to find the server to connect to.

Use this property to set the host that runs the server you want to connect to.


property UserName (line 137)

string UserName

The username you want to use to connect to the database server.

Set this property with the name of the user you want to use to connect to the database server.


property UserPassword (line 148)

string UserPassword

The password for the username you want to use to connect to the database server.

Set this property with the password for the user you want to use to connect to the database server.


property Connected (line 77)

boolean Connected

Determines whether a connection has been established to the remote source of data. [Publishes CustomConnection::Connected]

property DictionaryProperties (line 410)

array DictionaryProperties

Array containing all the information in array format about the dictionary

Use this property to provide information about the dictionary but using a PHP array instead a database table.


property Clients

Returns the clients of this database
This property is implemented in CustomConnection::Clients

property Connected

Determines whether a connection has been established to the remote source of data.
This property is implemented in CustomConnection::Connected

property DataSets

Provides an indexed array of all active datasets for a database component.
This property is implemented in CustomConnection::DataSets

property Name

Specifies the name for the component. The name is used as an identifier and should be unique.
This property is implemented in Component::Name

property Tag

A versatile property of every Component that can be used in any way you want
This property is implemented in Component::Tag

property ComponentCount

Indicates the number of components owned by the component.
This property is implemented in Component::ComponentCount

property Components

Lists all the components owned by this component.
This property is implemented in Component::Components

property ControlState

A flag to know the state of the control, csLoading, csDesigning
This property is implemented in Component::ControlState

property DataFieldValue

This property returns the value of the datafield if any.
This property is implemented in Component::DataFieldValue

property NamePath

Specifies the path to uniquely identify a component, qualified by the owner when required.
This property is implemented in Component::NamePath

property Owner

Indicates the component that is responsible for streaming and freeing this component.
This property is implemented in Component::Owner

property NamePath

Used to serialize/unserialize. It returns the full path to identify this component.
This property is implemented in Persistent::NamePath

property Owner

Owner of the component.
This property is implemented in Persistent::Owner

Methods

Summary:
__construct [Overrides CustomConnection::__construct()]
beginTrans
completeTrans
createDictionaryTable Creates the dictionary table on the database
databases Return all the databases using the connection information
dbDate
doConnect
doDisconnect
execute Executes a query
executelimit Executes a limited query on the database
extractIndexes Return indexes for a table
metaFields
param
prepare
prepareSP Prepares a stored procedure for execution
quoteStr
tables Return tables on this database

Defined in class CustomConnection

BeginTrans Begins a new transaction against the database server.
Close Closes the connection.
DoConnect Provides the interface for a method that opens a connection.
DoDisconnect Provides the interface for a method that terminates the connection.
loaded Initializes the component after the form file has been read into memory.
Open Opens the connection.

Defined in class Component

dumpChildrenJavascript Dumps the javascript code for all the children
dumpFormItems Dumps code just after the form tag, useful to dump hidden fields for state retrieving for non visible components
dumpHeaderCode Dumps header code required
dumpJavascript Dumps the javascript code needed by this component
hasValidDataField Returns true if a valid data field is attached to the component
init Initializes a component
loaded Initializes the component after the form file has been read into memory.
loadedChildren Calls childrens loaded
preinit Method called before init()
serializeChildren Serializes all children
unserializeChildren Unserializes all children by calling unserialize for all the components

Defined in class Persistent

serialize Stores this object into the session.
unserialize This method uses PHP reflection to iterate through published properties (the ones starting with get) and retrieve the properties stored by a previous serialize() call.

Defined in class Object

__construct Constructs an object and initializes its data before the object is first used.
className Returns a string indicating the type of the object instance (as opposed to the type of the variable passed as an argument).
classParent Returns the type of the immediate ancestor of a class.

Constructor __construct (line 214)

IBDatabase __construct( [ $aowner = null])

Overrides : CustomConnection::__construct() parent method not documented


Method beginTrans (line 63)

void beginTrans( [ $args = array()])

Parameters

  • $args:

Method completeTrans (line 68)

void completeTrans( [ $autocomplete = true])

Parameters

  • $autocomplete:

Method createDictionaryTable (line 424)

boolean createDictionaryTable( )

Creates the dictionary table on the database

Use this method to create the dictionary table on the database you are connection. This method issues the create table command and creates the table with the right structure. You have to connect to the database before use this method and Dictionary property must be set to the tablename.


Method databases (line 455)

array databases( )

Return all the databases using the connection information

This method returns an array with all the databases stored on the server. Not working yet.


Method dbDate (line 199)

void dbDate( $input)

Parameters

  • $input:

Method doConnect (line 280)

void doConnect( )


Method doDisconnect (line 296)

void doDisconnect( )


Method execute (line 230)

object execute( string $query, [array $params = array()])

Executes a query

Use this method to execute an SQL sentence on the database server

Parameters

  • string $query: Query to execute
  • array $params: Not used

Method executelimit (line 253)

object executelimit( string $query, integer $numrows, integer $offset, [array $params = array()])

Executes a limited query on the database

Use this method to execute an SQL sentence on the database server using LIMIT clause.

Parameters

  • string $query: Query to execute
  • integer $numrows: Rows to get
  • integer $offset: First row to start counting
  • array $params: Parameters to use on the query

Method extractIndexes (line 358)

array &extractIndexes( string $table, [boolean $primary = FALSE])

Return indexes for a table

This method extract the indexes from the table and returns an array with that information.

Parameters

  • string $table: Table name to look for
  • boolean $primary: If false, only non-primary keys will be returned

Method metaFields (line 50)

void metaFields( $tablename)

Parameters

  • $tablename:

Method param (line 204)

void param( $input)

Parameters

  • $input:

Method prepare (line 184)

void prepare( $query)

Parameters

  • $query:

Method prepareSP (line 194)

void prepareSP( $query)

Prepares a stored procedure for execution

Not finished

Parameters

  • $query:

Method quoteStr (line 209)

void quoteStr( $input)

Parameters

  • $input:

Method tables (line 468)

array tables( [ $ttype = false], [ $showSchema = false], [ $mask = false])

Return tables on this database

This method returns an array containing all the table names stored in the database.

Parameters

  • $ttype:
  • $showSchema:
  • $mask:

Events

Summary:
OnAfterConnect Occurs after a connection is established. [Publishes CustomConnection::OnAfterConnect]
OnAfterDisconnect Occurs after the connection closes. [Publishes CustomConnection::OnAfterDisconnect]
OnBeforeConnect Occurs immediately before establishing a connection. [Publishes CustomConnection::OnBeforeConnect]
OnBeforeDisconnect Occurs immediately before the connection closes. [Publishes CustomConnection::OnBeforeDisconnect]

Defined in class CustomConnection

OnCustomConnect
OnAfterConnect Occurs after a connection is established.
OnAfterDisconnect Occurs after the connection closes.
OnBeforeConnect Occurs immediately before establishing a connection.
OnBeforeDisconnect Occurs immediately before the connection closes.
OnLogin Occurs when an application connects to a database.

property OnAfterConnect (line 151)

mixed OnAfterConnect

Occurs after a connection is established. [Publishes CustomConnection::OnAfterConnect]

property OnAfterDisconnect (line 157)

mixed OnAfterDisconnect

Occurs after the connection closes. [Publishes CustomConnection::OnAfterDisconnect]

property OnBeforeConnect (line 154)

mixed OnBeforeConnect

Occurs immediately before establishing a connection. [Publishes CustomConnection::OnBeforeConnect]

property OnBeforeDisconnect (line 160)

mixed OnBeforeDisconnect

Occurs immediately before the connection closes. [Publishes CustomConnection::OnBeforeDisconnect]

property OnCustomConnect

This event is implemented in CustomConnection::OnCustomConnect

property OnAfterConnect

Occurs after a connection is established.
This event is implemented in CustomConnection::OnAfterConnect

property OnAfterDisconnect

Occurs after the connection closes.
This event is implemented in CustomConnection::OnAfterDisconnect

property OnBeforeConnect

Occurs immediately before establishing a connection.
This event is implemented in CustomConnection::OnBeforeConnect

property OnBeforeDisconnect

Occurs immediately before the connection closes.
This event is implemented in CustomConnection::OnBeforeDisconnect

property OnLogin

Occurs when an application connects to a database.
This event is implemented in CustomConnection::OnLogin

Javascript Events

Summary:

[none]

Documentation generated on Fri, 26 Dec 2008 11:45:33 +0100 by phpDocumentor 1.4.0a2