class BladeCompiler extends Compiler implements CompilerInterface (View source)

Traits

Methods

void
__construct(Filesystem $files, string $cachePath)

Create a new compiler instance.

from Compiler
string
getCompiledPath(string $path)

Get the path to the compiled version of a view.

from Compiler
bool
isExpired(string $path)

Determine if the view at the given path is expired.

from Compiler
string
compileEchoDefaults(string $value)

Compile the default values for the echo statement.

void
compile(string $path = null)

Compile the view at the given path.

string
getPath()

Get the path currently being compiled.

void
setPath(string $path)

Set the path currently being compiled.

string
compileString(string $value)

Compile the given Blade template contents.

string
stripParentheses(string $expression)

Strip the parentheses from the given expression.

void
extend(callable $compiler)

Register a custom Blade compiler.

array
getExtensions()

Get the extensions used by the compiler.

void
directive(string $name, callable $handler)

Register a handler for custom directives.

array
getCustomDirectives()

Get the list of custom directives.

void
setEchoFormat(string $format)

Set the echo format to be used by the compiler.

Details

in Compiler at line line 33
void __construct(Filesystem $files, string $cachePath)

Create a new compiler instance.

Parameters

Filesystem $files
string $cachePath

Return Value

void

Exceptions

InvalidArgumentException

in Compiler at line line 49
string getCompiledPath(string $path)

Get the path to the compiled version of a view.

Parameters

string $path

Return Value

string

in Compiler at line line 60
bool isExpired(string $path)

Determine if the view at the given path is expired.

Parameters

string $path

Return Value

bool

string compileEchoDefaults(string $value)

Compile the default values for the echo statement.

Parameters

string $value

Return Value

string

at line line 113
void compile(string $path = null)

Compile the view at the given path.

Parameters

string $path

Return Value

void

at line line 131
string getPath()

Get the path currently being compiled.

Return Value

string

at line line 142
void setPath(string $path)

Set the path currently being compiled.

Parameters

string $path

Return Value

void

at line line 153
string compileString(string $value)

Compile the given Blade template contents.

Parameters

string $value

Return Value

string

at line line 318
string stripParentheses(string $expression)

Strip the parentheses from the given expression.

Parameters

string $expression

Return Value

string

at line line 333
void extend(callable $compiler)

Register a custom Blade compiler.

Parameters

callable $compiler

Return Value

void

at line line 343
array getExtensions()

Get the extensions used by the compiler.

Return Value

array

at line line 355
void directive(string $name, callable $handler)

Register a handler for custom directives.

Parameters

string $name
callable $handler

Return Value

void

at line line 365
array getCustomDirectives()

Get the list of custom directives.

Return Value

array

at line line 376
void setEchoFormat(string $format)

Set the echo format to be used by the compiler.

Parameters

string $format

Return Value

void