Page Menu
Home
c4science
Search
Configure Global Search
Log In
Files
F105272091
XHPASTToken.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
Sat, Mar 15, 22:44
Size
934 B
Mime Type
text/x-php
Expires
Mon, Mar 17, 22:44 (2 d)
Engine
blob
Format
Raw Data
Handle
24954006
Attached To
rPHU libphutil
XHPASTToken.php
View Options
<?php
/**
* @group xhpast
*/
final
class
XHPASTToken
extends
AASTToken
{
public
function
getTypeName
()
{
if
(
empty
(
$this
->
typeName
))
{
$type_id
=
$this
->
typeID
;
if
(
$type_id
<=
255
)
{
$this
->
typeName
=
chr
(
$type_id
);
}
$this
->
typeName
=
parent
::
getTypeName
();
}
return
$this
->
typeName
;
}
public
function
isComment
()
{
static
$type_ids
=
null
;
if
(
$type_ids
===
null
)
{
$type_ids
=
array
(
$this
->
tree
->
getTokenTypeIDFromTypeName
(
'T_COMMENT'
)
=>
true
,
$this
->
tree
->
getTokenTypeIDFromTypeName
(
'T_DOC_COMMENT'
)
=>
true
,
);
}
return
isset
(
$type_ids
[
$this
->
typeID
]);
}
public
function
isAnyWhitespace
()
{
static
$type_ids
=
null
;
if
(
$type_ids
===
null
)
{
$type_ids
=
array
(
$this
->
tree
->
getTokenTypeIDFromTypeName
(
'T_WHITESPACE'
)
=>
true
,
);
}
return
isset
(
$type_ids
[
$this
->
typeID
]);
}
}
Event Timeline
Log In to Comment