const mixinafColdFeet::ColdFeet

afColdFeet::ColdFeet

(Service) - Creates client-side asset URIs.

fromClientUri

Source

abstract Uri fromClientUri(Uri uri)

Converts the given client URI (one that would normally be used by the browser to access the resource) into a cachable Cold Feet URI. Essentially this adds a Cold Feet prefix and digest to the given URI, as well as checking for URI validity and that the corresponding file exists.

The URI must be mapped by BedSheet's FileHandler service.

fromServerFile

Source

abstract Uri fromServerFile(File asset)

Converts the given asset File (on the server's file system) into a cachable Cold Feet URI that can be used by clients / browsers.

The asset must exist on the file system and be mapped by BedSheet's FileHandler service.