Exemplo n.º 1
0
 /**
  * return a collection of all this model.
  *
  * By calling this method it means that you expect many results. As such a
  * select() will always return an array (empty when there is no results)
  * unless you've modified the expectation (for exemple by calling first()
  * on the selector).
  *
  * @return
  *   a No2_SQLQuery object.
  */
 public static function all()
 {
     $query = new No2_SQLQuery(get_called_class(), No2_SQLQuery::EXPECT_MANY);
     $query->restrict_to(No2_SQLQuery::SELECT, true);
     return $query;
 }