public function getCollection($name)
    {
        $name = strtolower($name);

        if ($this->collections->containsKey($name)) {
            return $this->collections->get($name);
        }

        $this->collections->set($name, $this->createCollection($name));

        return $this->collections->get($name);
    }
public function getCollection($name)
    {
        $name = strtolower($name);

        if ($this->collections->containsKey($name)) {
            return $this->collections->get($name);
        }

        $this->collections->set($name, $this->createCollection($name));

        return $this->collections->get($name);
    }
public function getCollection ( $ name ) { $ name = strtolower ( $ name ) ; if ( $ this -> collections -> containsKey ( $ name ) ) { return $ this -> collections -> get ( $ name ) ; } $ this -> collections -> set ( $ name , $ this -> createCollection ( $ name ) ) ; return $ this -> collections -> get ( $ name ) ; }
Gets a Collection by name

Collections are idempotent, we create a collection if it does not exist
or return existing collections

@param  string $name The name of the Collection

@return Collection
Gets a Collection by name