public class BundleAction
extends java.lang.Object
Modifier and Type | Field and Description |
---|---|
protected java.lang.String |
actionPath |
protected java.lang.String |
bundleContentType |
protected java.lang.String |
bundleId |
protected char[] |
bundleIdMark |
protected HtmlStaplerBundlesManager |
bundlesManager |
protected java.lang.String |
contextPath |
protected boolean |
firstScriptTag |
protected boolean |
newAction |
protected java.util.List<java.lang.String> |
sources |
protected HtmlStaplerBundlesManager.Strategy |
strategy |
Constructor and Description |
---|
BundleAction(HtmlStaplerBundlesManager bundlesManager,
java.lang.String servletPath,
java.lang.String bundleContentType)
Creates new bundle action.
|
Modifier and Type | Method and Description |
---|---|
boolean |
acceptLink(java.lang.String src)
Returns
true if resource link should be collected into the bundle. |
protected java.lang.String |
buildStaplerUrl()
Builds stapler URL based on bundle action data.
|
void |
end()
Called on end of parsing.
|
java.lang.String |
processLink(java.lang.String src)
Process links.
|
char[] |
replaceBundleId(char[] content)
Replaces bundle marker with calculated bundle id.
|
protected final HtmlStaplerBundlesManager bundlesManager
protected final java.lang.String bundleContentType
protected final boolean newAction
protected final java.lang.String actionPath
protected final java.lang.String contextPath
protected final HtmlStaplerBundlesManager.Strategy strategy
protected java.lang.String bundleId
protected char[] bundleIdMark
protected java.util.List<java.lang.String> sources
protected boolean firstScriptTag
public BundleAction(HtmlStaplerBundlesManager bundlesManager, java.lang.String servletPath, java.lang.String bundleContentType)
public boolean acceptLink(java.lang.String src)
true
if resource link should be collected into the bundle. Returns
false
for resources that has to ignored or when no link existed (null
).
By default, ignores resource links that contains "jodd.unstaple" (usually set as dummy parameter name).
public java.lang.String processLink(java.lang.String src)
null
indicating
that collection is going on and the original link should be removed.protected java.lang.String buildStaplerUrl()
public void end()
public char[] replaceBundleId(char[] content)
RESOURCE_ONLY
strategy.Copyright © 2003-present Jodd Team