Page Menu
Home
WickedGov Phorge
Search
Configure Global Search
Log In
Files
F1430300
IteratorDecorator.php
No One
Temporary
Actions
Download File
Edit File
Delete File
View Transforms
Subscribe
Flag For Later
Award Token
Size
1 KB
Referenced Files
None
Subscribers
None
IteratorDecorator.php
View Options
<?php
/**
* @license GPL-2.0-or-later
*/
/**
* Allows extending classes to decorate an Iterator with
* reduced boilerplate.
*
* @stable to extend
* @ingroup Maintenance
*/
abstract
class
IteratorDecorator
implements
Iterator
{
protected
Iterator
$iterator
;
/**
* @stable to call
*
* @param Iterator $iterator
*/
public
function
__construct
(
Iterator
$iterator
)
{
$this
->
iterator
=
$iterator
;
}
/**
* @inheritDoc
* @stable to override
*/
#[\ReturnTypeWillChange]
public
function
current
()
{
return
$this
->
iterator
->
current
();
}
/**
* @inheritDoc
* @stable to override
*/
#[\ReturnTypeWillChange]
public
function
key
()
{
return
$this
->
iterator
->
key
();
}
/**
* @inheritDoc
* @stable to override
*/
public
function
next
():
void
{
$this
->
iterator
->
next
();
}
/**
* @inheritDoc
* @stable to override
*/
public
function
rewind
():
void
{
$this
->
iterator
->
rewind
();
}
/**
* @inheritDoc
* @stable to override
*/
public
function
valid
():
bool
{
return
$this
->
iterator
->
valid
();
}
}
File Metadata
Details
Attached
Mime Type
text/x-php
Expires
Sat, May 16, 18:36 (6 h, 17 m)
Storage Engine
local-disk
Storage Format
Raw Data
Storage Handle
f7/86/fff33a4c648030f7f7398fede850
Default Alt Text
IteratorDecorator.php (1 KB)
Attached To
Mode
rMWPROD MediaWiki Production
Attached
Detach File
Event Timeline
Log In to Comment