private function getDatabase($name)
    {
        foreach ($this->getDataModels() as $dm) {
            foreach ($dm->getDatabases() as $db) {
                if ($db->getName() == $name) {
                    return $db;
                }
            }
        }
    }
private function getDatabase($name)
    {
        foreach ($this->getDataModels() as $dm) {
            foreach ($dm->getDatabases() as $db) {
                if ($db->getName() == $name) {
                    return $db;
                }
            }
        }
    }
private function getDatabase ( $ name ) { foreach ( $ this -> getDataModels ( ) as $ dm ) { foreach ( $ dm -> getDatabases ( ) as $ db ) { if ( $ db -> getName ( ) == $ name ) { return $ db ; } } } }
Search through all data models looking for matching database.

@return Database or NULL if none found.
Search through all data models looking for matching database .