Groovy Documentation

org.grails.plugin.resource
[Groovy] Class CSSPreprocessorResourceMapper

java.lang.Object
  org.grails.plugin.resource.CSSPreprocessorResourceMapper

class CSSPreprocessorResourceMapper

This mapper is the first phase of CSS rewriting. It will find any relative URIs in the CSS and convert them to a "resource:" so that later after mappers have been applied, the URIs can be fixed up and restored to URIs relative to the new CSS output file's location. For example a bundle or "hashandcache" mapper may move the CSS file to a completely different place, thus breaking all the relative links to images.

Authors:
Marc Palmer (marc@grailsrocks.com)
Luke Daley (ld@ldaley.com)
See Also:
CSSRewriter


Property Summary
static java.lang.Object defaultIncludes

java.lang.Object grailsResourceProcessor

java.lang.Object phase

 
Constructor Summary
CSSPreprocessorResourceMapper()

 
Method Summary
java.lang.Object map(java.lang.Object resource, java.lang.Object config)

Find all url() and fix up the url if it is not absolute NOTE: This needs to run after any plugins that move resources around, but before any that obliterate the content i.e. before minify or gzip

 
Methods inherited from class java.lang.Object
java.lang.Object#wait(long, int), java.lang.Object#wait(long), java.lang.Object#wait(), java.lang.Object#equals(java.lang.Object), java.lang.Object#toString(), java.lang.Object#hashCode(), java.lang.Object#getClass(), java.lang.Object#notify(), java.lang.Object#notifyAll()
 

Property Detail

defaultIncludes

static java.lang.Object defaultIncludes


grailsResourceProcessor

java.lang.Object grailsResourceProcessor


phase

java.lang.Object phase


 
Constructor Detail

CSSPreprocessorResourceMapper

CSSPreprocessorResourceMapper()


 
Method Detail

map

java.lang.Object map(java.lang.Object resource, java.lang.Object config)
Find all url() and fix up the url if it is not absolute NOTE: This needs to run after any plugins that move resources around, but before any that obliterate the content i.e. before minify or gzip


 

Groovy Documentation