Page Menu
Home
Phabricator
Search
Configure Global Search
Log In
Files
F17826441
PhabricatorHTTPParameterTypeTableView.php
No One
Temporary
Actions
Download File
Edit File
Delete File
View Transforms
Subscribe
Mute Notifications
Award Token
Flag For Later
Size
1 KB
Referenced Files
None
Subscribers
None
PhabricatorHTTPParameterTypeTableView.php
View Options
<?php
final
class
PhabricatorHTTPParameterTypeTableView
extends
AphrontView
{
private
$types
;
public
function
setHTTPParameterTypes
(
array
$types
)
{
assert_instances_of
(
$types
,
'AphrontHTTPParameterType'
);
$this
->
types
=
$types
;
return
$this
;
}
public
function
getHTTPParameterTypes
()
{
return
$this
->
types
;
}
public
function
render
()
{
$types
=
$this
->
getHTTPParameterTypes
();
$types
=
mpull
(
$types
,
null
,
'getTypeName'
);
$br
=
phutil_tag
(
'br'
);
$rows
=
array
();
foreach
(
$types
as
$name
=>
$type
)
{
$formats
=
$type
->
getFormatDescriptions
();
$formats
=
phutil_implode_html
(
$br
,
$formats
);
$examples
=
$type
->
getExamples
();
$examples
=
phutil_implode_html
(
$br
,
$examples
);
$rows
[]
=
array
(
$name
,
$formats
,
$examples
,
);
}
$table
=
id
(
new
AphrontTableView
(
$rows
))
->
setHeaders
(
array
(
pht
(
'Type'
),
pht
(
'Formats'
),
pht
(
'Examples'
),
))
->
setColumnClasses
(
array
(
'pri top'
,
'top'
,
'wide top prewrap'
,
));
return
$table
;
}
}
File Metadata
Details
Attached
Mime Type
text/x-php
Expires
Mon, Jul 28, 7:18 AM (4 d, 2 h ago)
Storage Engine
blob
Storage Format
Encrypted (AES-256-CBC)
Storage Handle
8233192
Default Alt Text
PhabricatorHTTPParameterTypeTableView.php (1 KB)
Attached To
Mode
rP Phabricator
Attached
Detach File
Event Timeline
Log In to Comment