original_string: public static function firstOrFail(
          $query = [],
          array $projection = [],
          bool $useCache = false
      ) {
          return self::getDataMapperInstance()->firstOrFail(
              $query,
              $projection,
              $useCache
          );
      }
code: public static function firstOrFail(
          $query = [],
          array $projection = [],
          bool $useCache = false
      ) {
          return self::getDataMapperInstance()->firstOrFail(
              $query,
              $projection,
              $useCache
          );
      }
code_tokens: public static function firstOrFail ( $ query = [ ] , array $ projection = [ ] , bool $ useCache = false ) { return self :: getDataMapperInstance ( ) -> firstOrFail ( $ query , $ projection , $ useCache ) ; }
docstring: Gets the first entity of this kind that matches the query. If no
  document was found, throws ModelNotFoundException.
  
  @param mixed $query      mongoDB selection criteria
  @param array $projection fields to project in Mongo query
  @param bool  $useCache   retrieves the entity through a CacheableCursor
  
  @throws ModelNotFoundException if no document was found
  
  @return ActiveRecord
docstring_tokens: Gets the first entity of this kind that matches the query . If no document was found throws ModelNotFoundException .