Package ro.isdc.wro.model.resource.processor.support.CssUrlInspector

Examples of ro.isdc.wro.model.resource.processor.support.CssUrlInspector.ItemHandler


      writer.close();
    }
  }

  private ItemHandler createUrlItemHandler(final String cssUri) {
    return new ItemHandler() {
      public String replace(final String originalDeclaration, final String originalUrl) {
        Validate.notNull(originalUrl);
        String replacement = originalDeclaration;
        if (isReplaceNeeded(originalUrl)) {
          final String modifiedUrl = replaceImageUrl(cssUri.trim(), cleanImageUrl(originalUrl));
View Full Code Here


  }

  @Test
  public void shouldRemoveOriginalUrl()
      throws Exception {
    compareResultsFromFolderUsingProcessor("expectedEmptyReplace", createProcessorWithHandler(new ItemHandler() {
      public String replace(final String originalDeclaration, final String originalUrl) {
        return originalDeclaration.replace(originalUrl, "");
      }
    }));
  }
View Full Code Here

  }

  @Test
  public void shouldRemoveOriginalUrl()
      throws Exception {
    compareResultsFromFolderUsingProcessor("expectedDataUri", createProcessorWithHandler(new ItemHandler() {
      public String replace(final String originalDeclaration, final String originalUrl) {
        return originalDeclaration.replace(originalUrl, "");
      }
    }));
  }
View Full Code Here

TOP

Related Classes of ro.isdc.wro.model.resource.processor.support.CssUrlInspector.ItemHandler

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.