org.apache.wicket.util.resource
Class ResourceUtils

java.lang.Object
  extended by org.apache.wicket.util.resource.ResourceUtils

public class ResourceUtils
extends Object

Author:
Juergen Donnerstag

Nested Class Summary
static class ResourceUtils.PathLocale
           
 
Field Summary
static String MIN_POSTFIX_DEFAULT
          The default postfix for minified names (ex: /css/mystyle.min.css)
 
Constructor Summary
ResourceUtils()
           
 
Method Summary
static ResourceUtils.PathLocale getLocaleFromFilename(String path)
          Extract the locale from the filename
static String getMinifiedName(String name, String minPostfix)
          Return the minified version for a given resource name.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

MIN_POSTFIX_DEFAULT

public static final String MIN_POSTFIX_DEFAULT
The default postfix for minified names (ex: /css/mystyle.min.css)

See Also:
Constant Field Values
Constructor Detail

ResourceUtils

public ResourceUtils()
Method Detail

getMinifiedName

public static String getMinifiedName(String name,
                                     String minPostfix)
Return the minified version for a given resource name. For example '/css/coolTheme.css' becomes '/css/coolTheme.min.css'

Parameters:
name - The original resource name
minPostfix - The postfix to use for minified name
Returns:
The minified resource name

getLocaleFromFilename

public static ResourceUtils.PathLocale getLocaleFromFilename(String path)
Extract the locale from the filename

Parameters:
path - The file path
Returns:
The updated path, without the locale


Copyright © 2006–2015 Apache Software Foundation. All rights reserved.