databases
[ class tree: databases ] [ index: databases ] [ all elements ]

Class: MySQLDatabase

Source Location: /databases/mysql/MySQLDatabase.class.php

Class Overview

Database
   |
   --MySQLDatabase



Author(s):

Version:

  • 0.2.02

Copyright:

  • Copyright (C) 2004 Daniel Plücken <daniel@debakel.net>

    This library is free software; you can redistribute it and/or modify it under the terms of the GNU Lesser General Public License as published by the Free Software Foundation; either version 2.1 of the License.

    This library is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU Lesser General Public License for more details.

    You should have received a copy of the GNU Lesser General Public License along with this library; if not, write to the Free Software Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA

Methods


Inherited Variables

Inherited Methods

Class: Database

Database::Database()
Constructor
Database::addDBT()
Adds a databasetable's reference to this object of a database.
Database::addView()
Adds a view's reference to this object of a database.
Database::getDatabase()
Returns the databasename.
Database::getDatabaseTables()
Returns the array of references to the databasetables.
Database::getLastQuery()
Returns the last stored database query.
Database::getName()
Returns the databasename. This method is an alias for the method getDatabase()
Database::getResourceID()
Returns the id of the connection resource to the database host.
Database::getViews()
Returns the array of references to the views.
Database::setErrorCallback()
Sets the name of the function that should be invoked on a connection error.
Database::setParent()
Sets the parent of this object.

Class Details

[line 88]


Tags:

author:  Daniel Plücken <daniel@debakel.net>
version:  0.2.02
copyright:  

Copyright (C) 2004 Daniel Plücken <daniel@debakel.net>

This library is free software; you can redistribute it and/or modify it under the terms of the GNU Lesser General Public License as published by the Free Software Foundation; either version 2.1 of the License.

This library is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU Lesser General Public License for more details.

You should have received a copy of the GNU Lesser General Public License along with this library; if not, write to the Free Software Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA

license:  GNU Lesser General Public License


[ Top ]


Class Methods


static method __parse_vars [line 380]

static string __parse_vars( string $database, string $query, string $text)

This function parses pseudo variables in a text on SQL-errors.

  • %database% -> The name of this database.
  • %query% -> The query which was tried to execute.




Tags:

version:  1.0
since:  0.1.5
access:  public


Parameters:

string   $database  
string   $query  
string   $text  

[ Top ]

constructor MySQLDatabase [line 102]

MySQLDatabase MySQLDatabase( string $name, [object $parent = ""])

Constructor



Tags:

version:  1.21
since:  0.1.0
access:  public


Parameters:

string   $name  
object   $parent  

[ Top ]

method dump [line 206]

boolean dump( [string $target = "./__dumps"], [string $regExp = ""])

Dumps this Database.



Tags:

version:  1.1
since:  0.1.1
access:  public


Parameters:

string   $target  
string   $regExp   Makes sure that only database-tables were stored, which names matching the given regular expression.

[ Top ]

method import [line 591]

boolean import( string $str_dump)

Imports a given SQL-string into this Database.



Tags:

version:  1.0
since:  0.1.43
access:  public


Parameters:

string   $str_dump   The dump to import.

[ Top ]

method importDump [line 262]

boolean importDump( [string $source = "./__dumps"], [string $regExp = ""])

Imports Dumps from given source to this database.



Tags:

version:  1.1
since:  0.1.1
access:  public


Parameters:

string   $source  
string   $regExp   Makes sure that only files will be imported, which names matching the given regular expression.

[ Top ]

method importSingleDump [line 305]

boolean importSingleDump( [string $source = "http://www.test.de/getMySQLTable.php"])

Researches a whole folder to import dumped data from it.



Tags:

version:  1.5
since:  0.1.7
access:  public


Parameters:

string   $source   The source resource of the MySQL-Dump.

[ Top ]

method probeConnection [line 623]

boolean probeConnection( )

Probes whether there is a connection to the databasehost, if not it will attempt to connect to the host.



Tags:

version:  1.21
since:  0.1.1
access:  public


[ Top ]

method query [line 402]

boolean query( string $sqlOrder, [boolean $no_logs = false])

Will query this database.



Tags:

version:  1.6
since:  0.1.0
access:  public


Parameters:

string   $sqlOrder  
boolean   $no_logs  

[ Top ]

method researchTables [line 154]

void researchTables( [string $regExp = ""], [boolean $resFld = false])

Sets the references to objects of database-tables to the attribute $this->dbt.



Tags:

version:  1.11
since:  0.1.0
access:  public


Parameters:

string   $regExp   Makes sure that only database-tables were stored, which names matching the given regular expression.
boolean   $resFld   Cause whether the tables's fields should be research too.

[ Top ]


Documentation generated on Thu, 05 Jun 2008 19:14:00 +0200 by phpDocumentor 1.4.1