| 1 | <?php |
||
| 10 | trait ItFetchesMySQLDatabases |
||
| 11 | { |
||
| 12 | /** |
||
| 13 | * Fetch MySQLDatabases. |
||
| 14 | */ |
||
| 15 | protected function fetchMySQLDatabases() |
||
| 33 | |||
| 34 | /** |
||
| 35 | * Get mysql database from databases by name. |
||
| 36 | * |
||
| 37 | * @param $databases |
||
| 38 | * @param $database_name |
||
| 39 | * @return mixed|null |
||
| 40 | */ |
||
| 41 | protected function getMySQLDatabaseByName($databases, $database_name) |
||
| 52 | } |
||
| 53 |
In PHP it is possible to write to properties without declaring them. For example, the following is perfectly valid PHP code:
Generally, it is a good practice to explictly declare properties to avoid accidental typos and provide IDE auto-completion: