Menu

## EnvResolver
in package
Uses PathsTrait

EnvResolver.php : 10

### Table of Contents

#### Properties

$dotenv : Dotenv
$allFiles : Arrayable|null
  All files in the environment directory
$env : Arrayable
  Resolved environment variables
$path : mixed|string
  The path to the environment directory

#### Methods

__construct() : mixed
all() : Arrayable
  Scan the environment directory and list all the files discovered grouped by type
appRoot() : string
  The root folder of the application.
envPath() : string
getDirFor() : string|null
  Get the directory for a given alias
getEnv() : Arrayable
  Get the environment variables
getEnvFilePath() : string
  Get the environment file path
getEnvKeys() : mixed
mediaPath() : string
  The path to the resources directory.
phpPath() : string
phpVersion() : string
publicPath() : string
  The directory where the frontend assets are stored.
resolve() : void
  Load the environment variables
resolveDatabaseConfigs() : void
resolveDotEnv() : void
  Resolve the .env files in our environment We let dotenv handle this
resolveIniFiles() : void
  Resolve the ini files in our environment If we find a database configuration file, we shall mark it as the database configuration file
resolvePhpFiles() : void
extractFromIniFile() : void

### Properties

#### $dotenv

EnvResolver.php : 20
`public Dotenv $dotenv`

#### $allFiles

EnvResolver.php : 32

All files in the environment directory

`private Arrayable|null $allFiles`

#### $env

EnvResolver.php : 16

Resolved environment variables

`private Arrayable $env`

#### $path

EnvResolver.php : 26

The path to the environment directory

`private mixed|string $path`

### Methods

#### __construct()

EnvResolver.php : 35
`public __construct([string|null $path = 'Environment' ]) : mixed`

##### Parameters

$path : string|null = 'Environment'

#### all()

EnvResolver.php : 211

Scan the environment directory and list all the files discovered grouped by type

`public all([string|null $path = null ]) : Arrayable`

##### Parameters

$path : string|null = null

##### Return values

Arrayable

#### appRoot()

PathsTrait.php : 32

The root folder of the application.

`public appRoot([string|null $path = null ][, int $levels = 3 ]) : string`

##### Parameters

$path : string|null = null
$levels : int = 3

##### Return values

string

#### envPath()

PathsTrait.php : 50
`public envPath([string|null $path = null ]) : string`

##### Parameters

$path : string|null = null

##### Return values

string

#### getDirFor()

PathsTrait.php : 62

Get the directory for a given alias

`public getDirFor(string $aliasName) : string|null`

##### Parameters

$aliasName : string

##### Return values

string|null

#### getEnv()

EnvResolver.php : 258

Get the environment variables

`public getEnv() : Arrayable`

##### Return values

Arrayable

#### getEnvFilePath()

EnvResolver.php : 248

Get the environment file path

`public getEnvFilePath() : string`

##### Return values

string

#### getEnvKeys()

EnvResolver.php : 263
`public getEnvKeys() : mixed`

#### mediaPath()

PathsTrait.php : 21

The path to the resources directory.

`public mediaPath() : string`

##### Return values

string

#### phpPath()

PathsTrait.php : 45
`public phpPath() : string`

##### Return values

string

#### phpVersion()

PathsTrait.php : 40
`public phpVersion() : string`

##### Return values

string

#### publicPath()

PathsTrait.php : 13

The directory where the frontend assets are stored.

`public publicPath([ $path = null ]) : string`

##### Parameters

$path : = null

##### Return values

string

#### resolve()

EnvResolver.php : 49

Load the environment variables

`public resolve() : void`

#### resolveDatabaseConfigs()

EnvResolver.php : 283
`public resolveDatabaseConfigs(Filesystem $fs[, string|null $fileName = 'database.ini' ]) : void`

##### Parameters

$fs : Filesystem
$fileName : string|null = 'database.ini'

#### resolveDotEnv()

EnvResolver.php : 111

Resolve the .env files in our environment We let dotenv handle this

`public resolveDotEnv() : void`

#### resolveIniFiles()

EnvResolver.php : 155

Resolve the ini files in our environment If we find a database configuration file, we shall mark it as the database configuration file

`public resolveIniFiles() : void`

#### resolvePhpFiles()

EnvResolver.php : 129
`public resolvePhpFiles() : void`

#### extractFromIniFile()

EnvResolver.php : 271
`private extractFromIniFile(mixed $path) : void`

##### Parameters

$path : mixed

## Search results