Environment

Class
Final: Yes

Reads environment variables through PHP's native runtime.

Table of Contents

Interfaces

EnvironmentInterface

Reads process environment variables without binding callers to Composer APIs.

Methods

get()

Reads an environment variable.

 : string|null
Methods

get()

Public

Reads an environment variable.

public get( string  $name[, string|null  $default = null]) : string|null
Parameters
$name : string

Description

the environment variable name

$default : string|null = null

Description

the value returned when the variable is not defined

Return values
string|null

Description

the variable value, or the default when it is not defined