Page Menu
Home
c4science
Search
Configure Global Search
Log In
Files
F102044083
PhutilQueryString.php
No One
Temporary
Actions
Download File
Edit File
Delete File
View Transforms
Subscribe
Mute Notifications
Award Token
Subscribers
None
File Metadata
Details
File Info
Storage
Attached
Created
Sun, Feb 16, 13:12
Size
805 B
Mime Type
text/x-php
Expires
Tue, Feb 18, 13:12 (2 d)
Engine
blob
Format
Raw Data
Handle
24269486
Attached To
rPHU libphutil
PhutilQueryString.php
View Options
<?php
final
class
PhutilQueryString
extends
Phobject
{
private
$escaper
;
private
$argv
;
public
function
__construct
(
PhutilQsprintfInterface
$escaper
,
array
$argv
)
{
$this
->
escaper
=
$escaper
;
$this
->
argv
=
$argv
;
// This makes sure we throw immediately if there are errors in the
// parameters.
$this
->
getMaskedString
();
}
public
function
__toString
()
{
return
$this
->
getMaskedString
();
}
public
function
getUnmaskedString
()
{
return
$this
->
renderString
(
true
);
}
public
function
getMaskedString
()
{
return
$this
->
renderString
(
false
);
}
private
function
renderString
(
$unmasked
)
{
return
xsprintf
(
'xsprintf_query'
,
array
(
'escaper'
=>
$this
->
escaper
,
'unmasked'
=>
$unmasked
,
),
$this
->
argv
);
}
}
Event Timeline
Log In to Comment