function find($logicalPath, $options = array())
    {
        $path = new FileUtils\PathInfo($logicalPath);

        if ($path->isAbsolute()) {
            $realPath = $logicalPath;
        } else {
            $realPath = $this->loadPaths->find($logicalPath);
        }

        if (!is_file($realPath)) {
            return;
        }

        if (null === $realPath) {
            return;
        }

        if (@$options["bundled"]) {
            $asset = new BundledAsset($this, $realPath, $logicalPath);
        } else {
            $asset = new ProcessedAsset($this, $realPath, $logicalPath);
        }

        return $asset;
    }
function find($logicalPath, $options = array())
    {
        $path = new FileUtils\PathInfo($logicalPath);

        if ($path->isAbsolute()) {
            $realPath = $logicalPath;
        } else {
            $realPath = $this->loadPaths->find($logicalPath);
        }

        if (!is_file($realPath)) {
            return;
        }

        if (null === $realPath) {
            return;
        }

        if (@$options["bundled"]) {
            $asset = new BundledAsset($this, $realPath, $logicalPath);
        } else {
            $asset = new ProcessedAsset($this, $realPath, $logicalPath);
        }

        return $asset;
    }
function find ( $ logicalPath , $ options = array ( ) ) { $ path = new FileUtils \ PathInfo ( $ logicalPath ) ; if ( $ path -> isAbsolute ( ) ) { $ realPath = $ logicalPath ; } else { $ realPath = $ this -> loadPaths -> find ( $ logicalPath ) ; } if ( ! is_file ( $ realPath ) ) { return ; } if ( null === $ realPath ) { return ; } if ( @ $ options [ "bundled" ] ) { $ asset = new BundledAsset ( $ this , $ realPath , $ logicalPath ) ; } else { $ asset = new ProcessedAsset ( $ this , $ realPath , $ logicalPath ) ; } return $ asset ; }
Finds the logical path in the stack of load paths
and returns the Asset.

Example:

<?php
// Get the bundled application.js
$asset = $env->find('application.js', ['bundled' => true]);

@param string $logicalPath Path relative to the load path.
@param array $options

@return Asset
Finds the logical path in the stack of load paths and returns the Asset .