mirror of
https://github.com/Icinga/icingaweb2.git
synced 2025-07-28 00:04:04 +02:00
SimpleQuery: Provide a getter for the current iterator position
refs #8615
This commit is contained in:
parent
c891b9d356
commit
7662545c2a
@ -143,6 +143,16 @@ class SimpleQuery implements QueryInterface, Queryable, Iterator
|
|||||||
return $this->ds;
|
return $this->ds;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Return the current position of this query's iterator
|
||||||
|
*
|
||||||
|
* @return int
|
||||||
|
*/
|
||||||
|
public function getIteratorPosition()
|
||||||
|
{
|
||||||
|
return $this->iteratorPosition;
|
||||||
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Start or rewind the iteration
|
* Start or rewind the iteration
|
||||||
*/
|
*/
|
||||||
|
@ -605,6 +605,16 @@ class RepositoryQuery implements QueryInterface, SortRules, Iterator
|
|||||||
return $this->query->count();
|
return $this->query->count();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Return the current position of this query's iterator
|
||||||
|
*
|
||||||
|
* @return int
|
||||||
|
*/
|
||||||
|
public function getIteratorPosition()
|
||||||
|
{
|
||||||
|
return $this->query->getIteratorPosition();
|
||||||
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Start or rewind the iteration
|
* Start or rewind the iteration
|
||||||
*/
|
*/
|
||||||
|
@ -69,6 +69,16 @@ abstract class DataView implements QueryInterface, SortRules, IteratorAggregate
|
|||||||
return $this->getQuery();
|
return $this->getQuery();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Return the current position of the result set's iterator
|
||||||
|
*
|
||||||
|
* @return int
|
||||||
|
*/
|
||||||
|
public function getIteratorPosition()
|
||||||
|
{
|
||||||
|
return $this->query->getIteratorPosition();
|
||||||
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Get the query name this data view relies on
|
* Get the query name this data view relies on
|
||||||
*
|
*
|
||||||
|
Loading…
x
Reference in New Issue
Block a user