Page Menu
Home
WickedGov Phorge
Search
Configure Global Search
Log In
Files
F4149042
SingleLineContext.php
No One
Temporary
Actions
Download File
Edit File
Delete File
View Transforms
Subscribe
Flag For Later
Award Token
Size
526 B
Referenced Files
None
Subscribers
None
SingleLineContext.php
View Options
<?php
declare
(
strict_types
=
1
);
namespace
Wikimedia\Parsoid\Html2Wt
;
/**
* Stack and helpers to enforce single-line context while serializing.
*/
class
SingleLineContext
{
// PORT-TODO document
private
array
$stack
=
[];
public
function
enforce
():
void
{
$this
->
stack
[]
=
true
;
}
public
function
enforced
():
bool
{
return
count
(
$this
->
stack
)
>
0
&&
end
(
$this
->
stack
);
}
public
function
disable
():
void
{
$this
->
stack
[]
=
false
;
}
public
function
pop
():
void
{
array_pop
(
$this
->
stack
);
}
}
File Metadata
Details
Attached
Mime Type
text/x-php
Expires
Aug 19 2026, 19:01 (6 w, 4 d ago)
Storage Engine
local-disk
Storage Format
Raw Data
Storage Handle
4b/ae/f3e65082e93d102f640b0425724c
Default Alt Text
SingleLineContext.php (526 B)
Attached To
Mode
rMWPROD MediaWiki Production
Attached
Detach File
Event Timeline
Log In to Comment