Property | Type | Description | |
---|---|---|---|
$exception | array | Stores messages Exception thrown |
Method | Description | |
---|---|---|
beginTransaction ( ) | ||
clearStyle ( string $value ) : string | Removes the style markup in html tags, derived from a text editor | |
commit ( ) | ||
css ( ) : void | PDO4You Style | |
delete ( string $jarr, string $use = null ) : array | Method to delete a record in the database | |
exec ( $query ) | ||
execute ( string $json, string $use = null ) : array | Method to execute a statement in the database | |
fireAlert ( string $text, object $error ) : void | Triggers a warning via email to the system administrator | |
getConnection ( ) : string | Method to retrieve the name of the current instance of connection | |
getDatahost ( ) : string | Method to retrieve the server name | |
getDataport ( ) : string | Method to retrieve the port number of the server | |
getDriver ( ) : string | Method to retrieve the name of the current driver | |
getInstance ( string $alias = 'standard', string $type = null, string $user = null, string $pass = null, array $option = null ) : object | Method to get a single instance of the database per connection | |
insert ( string $jarr, string $use = null ) : array | Method to insert a new record in the database | |
lastId ( string $sequence = null ) : array | Method that returns the ID of the last inserted row or sequence value Database such as MS SQL Server, PostgreSQL, among others, they make use variable sequence | |
lastInsertId ( $name ) | ||
query ( $query ) | ||
rollBack ( ) | ||
rowCount ( ) : string | Method that returns the number of rows affected by the last CRUD (INSERT, SELECT, UPDATE, or DELETE) | |
select ( string $sql, string $use = null ) : array | Method referring to the fetchAll(PDO::FETCH_ASSOC) | |
selectAll ( string $sql, string $use = null ) : array | Method referring to the fetchAll(PDO::FETCH_BOTH) | |
selectNum ( string $sql, string $use = null ) : array | Method referring to the fetchAll(PDO::FETCH_NUM) | |
selectObj ( string $sql, string $use = null ) : object | Method referring to the fetchAll(PDO::FETCH_OBJ) | |
setInstance ( string $alias ) | Method for setting a connection instance | |
setPersistent ( boolean $persistent = false ) | Method for defining the type of communication with the database The default connection is not persistent | |
setSettings ( string $settings ) | Method to set the file path which contains the settings for each adapter connection with a database | |
showAvailableDrivers ( ) : void | Method to display the PDO drivers installed and supported by the server | |
showServerInfo ( ) : void | Method to display details about the target server's database connected | |
update ( string $jarr, string $use = null ) : array | Method to update a record in the database |
Method | Description | |
---|---|---|
__clone ( ) | As the builder, we make __clone private to prevent cloning instance of the class | |
__construct ( ) | The constructor is set to private, preventing direct instance of the class | |
countWhere ( mixed $value = 1, string $operator = '==', string $conditional = 1 ) : integer | Returns the sum of occurrences, in an array of a given condition satisfied | |
executeQuery ( string $jarr, string $type, string $use ) : array | Method for manipulation of records in the database | |
getErrorInfo ( PDOException $e, boolean $debug = false ) : array | Method to capture the error information of an Exception | |
getHandle ( string $alias ) : object | Method to return an object PDO connection | |
getSettings ( ) : string | Method to retrieve the path of the file that contains the configuration of adapters | |
highlightSource ( string $fileName, string $lineNumber, string $showLines = 5 ) : string | Method to highlight the syntax of a code | |
parseJSON ( string $json ) : array | Method that converts a string in JSON format for Array | |
parse_ini_file_advanced ( string $filename ) : array | Interprets an INI file with heritage section | |
selectRecords ( string $query, string $type, string $use, boolean $count = true ) : mixed | Method to query records in the database | |
setConnection ( string $alias ) | Method to define which the current instance of connection | |
setDatahost ( string $host ) | Method to set the server name | |
setDataport ( string $port ) | Method to set the port number of the server | |
setHandle ( string $alias, PDO $instance ) | Method for assigning a new object instance PDO connection | |
singleton ( string $alias, string $driver, string $user, string $pass, array $option ) : void | Method Singleton connection | |
stackTrace ( PDOException $e, boolean $show = true ) : void | Method to display the stack trace of an error Exception |
public static clearStyle ( string $value ) : string | ||
$value | string | The input string |
return | string |
public static getConnection ( ) : string | ||
return | string |
public static getDatahost ( ) : string | ||
return | string |
public static getDataport ( ) : string | ||
return | string |
public static getInstance ( string $alias = 'standard', string $type = null, string $user = null, string $pass = null, array $option = null ) : object | ||
$alias | string | Pseudonym that will be used as a pointer to an instance of established connection |
$type | string | Connection type if using "Initial Setup" or "Full DSN" |
$user | string | Username of the database |
$pass | string | Password of the database |
$option | array | Configuration the connection driver |
return | object |
public static setInstance ( string $alias ) | ||
$alias | string | Pseudonym of a connection instance |
public static setPersistent ( boolean $persistent = false ) | ||
$persistent | boolean | Sets a persistent connection |
public static setSettings ( string $settings ) | ||
$settings | string | Path of the file that contains the configuration of adapters |
public static showAvailableDrivers ( ) : void | ||
return | void |
public static showServerInfo ( ) : void | ||
return | void |
public static array $exception | ||
return | array |