BladeMapper
class BladeMapper (View source)
Properties
| protected Factory | $factory | The view factory instance.  | 
                |
| protected BladeCompiler | $bladeCompiler | The Blade compiler instance.  | 
                
Methods
Map cached view paths to their original paths.
Find the compiled view file for the given compiled path.
Get the list of known paths from the compiler engine.
Filter out the view data that should not be shown in the exception report.
Detect the line number in the original blade file.
Compile the source map for the given blade file.
Add line numbers to echo statements.
Add line numbers to blade statements.
Add line numbers to blade components.
Insert a line number at the given position.
Trim empty lines from the given value.
Find the closest line number mapping in the given source map.
Details
        
                            
    __construct(Factory $factory, BladeCompiler $bladeCompiler)
        
    
    Create a new Blade mapper instance.
        
                            FlattenException
    map(FlattenException $exception)
        
    
    Map cached view paths to their original paths.
        
                    protected        string|null
    findCompiledView(string $compiledPath)
        
    
    Find the compiled view file for the given compiled path.
        
                    protected        array<string,string>
    getKnownPaths()
        
    
    Get the list of known paths from the compiler engine.
        
                    protected        array<string,mixed>
    filterViewData(array $data)
        
    
    Filter out the view data that should not be shown in the exception report.
        
                    protected        int
    detectLineNumber(string $filename, int $compiledLineNumber)
        
    
    Detect the line number in the original blade file.
        
                    protected        string
    compileSourcemap(string $value)
        
    
    Compile the source map for the given blade file.
        
                    protected        string
    addEchoLineNumbers(string $value)
        
    
    Add line numbers to echo statements.
        
                    protected        string
    addStatementLineNumbers(string $value)
        
    
    Add line numbers to blade statements.
        
                    protected        string
    addBladeComponentLineNumbers(string $value)
        
    
    Add line numbers to blade components.
        
                    protected        string
    insertLineNumberAtPosition(int $position, string $value)
        
    
    Insert a line number at the given position.
        
                    protected        string
    trimEmptyLines(string $value)
        
    
    Trim empty lines from the given value.
        
                    protected        int
    findClosestLineNumberMapping(string $map, int $compiledLineNumber)
        
    
    Find the closest line number mapping in the given source map.