略微加速

PHP官方手册 - 互联网笔记

PHP - Manual: PhpToken::__toString

2024-05-02

PhpToken::__toString

(PHP 8)

PhpToken::__toStringReturns the textual content of the token.

说明

public PhpToken::__toString(): string

Returns the textual content of the token.

参数

此函数没有参数。

返回值

A textual content of the token.

范例

示例 #1 PhpToken::__toString() example

<?php
$token 
= new PhpToken(T_ECHO'echo');
echo 
$token;

以上例程会输出:

echo

参见

  • token_name() - 获取提供的 PHP 解析器代号的符号名称
add a noteadd a note

User Contributed Notes

There are no user contributed notes for this page.

官方地址:https://www.php.net/manual/en/phptoken.tostring.php

北京半月雨文化科技有限公司.版权所有 京ICP备12026184号-3