mirror of
https://github.com/rsyslog/loganalyzer.git
synced 2025-09-26 11:19:26 +02:00
php7: Upgraded constructors in all logstream classes
This commit is contained in:
parent
4adc735142
commit
47714eaa04
@ -65,6 +65,9 @@ class LogStreamDB extends LogStream {
|
||||
|
||||
// Constructor
|
||||
public function LogStreamDB($streamConfigObj) {
|
||||
self::__construct($streamConfigObj);
|
||||
}
|
||||
public function __construct ($streamConfigObj) {
|
||||
$this->_logStreamConfigObj = $streamConfigObj;
|
||||
|
||||
if ( $this->_logStreamConfigObj->DBType == DB_MYSQL )
|
||||
|
@ -64,6 +64,9 @@ class LogStreamDisk extends LogStream {
|
||||
|
||||
// Constructor
|
||||
public function LogStreamDisk($streamConfigObj) {
|
||||
self::__construct($streamConfigObj);
|
||||
}
|
||||
public function __construct ($streamConfigObj) {
|
||||
$this->_logStreamConfigObj = $streamConfigObj;
|
||||
}
|
||||
|
||||
|
@ -69,6 +69,10 @@ class LogStreamMongoDB extends LogStream {
|
||||
|
||||
// Constructor
|
||||
public function LogStreamMongoDB($streamConfigObj) {
|
||||
self::__construct($streamConfigObj);
|
||||
}
|
||||
|
||||
public function __construct ($streamConfigObj) {
|
||||
$this->_logStreamConfigObj = $streamConfigObj;
|
||||
|
||||
// Probe if a function exists!
|
||||
|
@ -61,20 +61,15 @@ class LogStreamPDO extends LogStream {
|
||||
|
||||
// Constructor
|
||||
public function LogStreamPDO($streamConfigObj) {
|
||||
self::__construct($streamConfigObj);
|
||||
}
|
||||
|
||||
public function __construct ($streamConfigObj) {
|
||||
$this->_logStreamConfigObj = $streamConfigObj;
|
||||
|
||||
// Verify if Extension is enabled
|
||||
if ( extension_loaded('pdo') == 0 )
|
||||
DieWithFriendlyErrorMsg("Error, PDO Extensions are not enabled or installed! This Source can not operate.");
|
||||
|
||||
/*
|
||||
if ( $this->_logStreamConfigObj->DBType == DB_MYSQL )
|
||||
{
|
||||
// Probe if a function exists!
|
||||
if ( !function_exists("mysql_connect") )
|
||||
DieWithFriendlyErrorMsg("Error, MYSQL Extensions are not enabled! Function 'mysql_connect' does not exist.");
|
||||
}
|
||||
*/
|
||||
}
|
||||
|
||||
/**
|
||||
|
Loading…
x
Reference in New Issue
Block a user