mirror of
https://github.com/Karaka-Management/phpOMS.git
synced 2026-02-12 14:58:42 +00:00
Add getters for connection
This commit is contained in:
parent
69123a0b24
commit
663dd31ad0
|
|
@ -110,6 +110,42 @@ abstract class ConnectionAbstract implements ConnectionInterface
|
||||||
return $this->status;
|
return $this->status;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Get database name.
|
||||||
|
*
|
||||||
|
* @return string
|
||||||
|
*
|
||||||
|
* @since 1.0.0
|
||||||
|
*/
|
||||||
|
public function getDatabase() : string
|
||||||
|
{
|
||||||
|
return $this->dbdata['database'];
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Get database host.
|
||||||
|
*
|
||||||
|
* @return string
|
||||||
|
*
|
||||||
|
* @since 1.0.0
|
||||||
|
*/
|
||||||
|
public function getHost() : string
|
||||||
|
{
|
||||||
|
return $this->dbdata['host'];
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Get database port.
|
||||||
|
*
|
||||||
|
* @return int
|
||||||
|
*
|
||||||
|
* @since 1.0.0
|
||||||
|
*/
|
||||||
|
public function getPort() : int
|
||||||
|
{
|
||||||
|
return (int) $this->dbdata['port'];
|
||||||
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Get table prefix.
|
* Get table prefix.
|
||||||
*
|
*
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue
Block a user