Page Menu
Home
c4science
Search
Configure Global Search
Log In
Files
F92975443
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
Mon, Nov 25, 07:17
Size
934 B
Mime Type
text/x-php
Expires
Wed, Nov 27, 07:17 (2 d)
Engine
blob
Format
Raw Data
Handle
22550829
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