Page Menu
Home
c4science
Search
Configure Global Search
Log In
Files
F73749315
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
Wed, Jul 24, 05:25
Size
934 B
Mime Type
text/x-php
Expires
Fri, Jul 26, 05:25 (1 d, 23 h)
Engine
blob
Format
Raw Data
Handle
19261787
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