mirror of
https://github.com/Icinga/icingaweb2-module-director.git
synced 2026-06-04 22:32:55 -04:00
DbObject: add hasConnection() helper method
This commit is contained in:
parent
f300bdca89
commit
d522cb8d2b
1 changed files with 6 additions and 0 deletions
|
|
@ -472,10 +472,16 @@ abstract class DbObject
|
|||
return $this->db;
|
||||
}
|
||||
|
||||
public function hasConnection()
|
||||
{
|
||||
return $this->connection !== null;
|
||||
}
|
||||
|
||||
public function getConnection()
|
||||
{
|
||||
return $this->connection;
|
||||
}
|
||||
|
||||
/**
|
||||
* Lädt einen Datensatz aus der Datenbank und setzt die entsprechenden
|
||||
* Eigenschaften dieses Objekts
|
||||
|
|
|
|||
Loading…
Reference in a new issue