Documentation

ParserFactory
in package

Table of Contents

Methods

createForHostVersion()  : Parser
Create a parser targeting the host PHP version, that is the PHP version we're currently running on. This parser will not use any token emulation.
createForNewestSupportedVersion()  : Parser
Create a parser targeting the newest version supported by this library. Code for older versions will be accepted if there have been no relevant backwards-compatibility breaks in PHP.
createForVersion()  : Parser
Create a parser targeting the given version on a best-effort basis. The parser will generally accept code for the newest supported version, but will try to accommodate code that becomes invalid in newer versions or changes in interpretation.

Methods

createForHostVersion()

Create a parser targeting the host PHP version, that is the PHP version we're currently running on. This parser will not use any token emulation.

public createForHostVersion() : Parser
Return values
Parser

createForNewestSupportedVersion()

Create a parser targeting the newest version supported by this library. Code for older versions will be accepted if there have been no relevant backwards-compatibility breaks in PHP.

public createForNewestSupportedVersion() : Parser
Return values
Parser

createForVersion()

Create a parser targeting the given version on a best-effort basis. The parser will generally accept code for the newest supported version, but will try to accommodate code that becomes invalid in newer versions or changes in interpretation.

public createForVersion(PhpVersion $version) : Parser
Parameters
$version : PhpVersion
Return values
Parser

        
On this page

Search results