Module org.apache.wicket.core
Class ResourceBundleReference
java.lang.Object
org.apache.wicket.request.resource.ResourceReference
org.apache.wicket.resource.bundles.ResourceBundleReference
- All Implemented Interfaces:
Serializable
,IResourceBundle
,IClusterable
- Direct Known Subclasses:
ReplacementResourceBundleReference
A resource reference that wraps another resource to make it into a bundle. The resources that are
provided by the wrapped reference, have to be added with
addProvidedResources(org.apache.wicket.markup.head.HeaderItem...)
. Normally, you will
have to register this bundle in ResourceBundles
under
Application.getResourceBundles()
. Dependencies are inherited from the provided resources
if the bundle does not provide them.- Author:
- papegaaij
- See Also:
-
Nested Class Summary
Nested classes/interfaces inherited from class org.apache.wicket.request.resource.ResourceReference
ResourceReference.Key, ResourceReference.LambdaResourceReference, ResourceReference.UrlAttributes
-
Constructor Summary
ConstructorDescriptionResourceBundleReference
(ResourceReference bundleRef) Creates a new bundle reference from the given reference. -
Method Summary
Modifier and TypeMethodDescriptionvoid
addProvidedResources
(HeaderItem... items) Adds theHeaderItem
s that this bundle provides.Iterable<? extends HeaderItem>
Returns the resource.Methods inherited from class org.apache.wicket.request.resource.ResourceReference
canBeRegistered, equals, getExtension, getKey, getLocale, getName, getScope, getStyle, getUrlAttributes, getVariation, hashCode, of, of, toString
-
Constructor Details
-
ResourceBundleReference
Creates a new bundle reference from the given reference.- Parameters:
bundleRef
-
-
-
Method Details
-
getBundleReference
- Returns:
- The resource reference that is served for this bundle
-
addProvidedResources
Adds theHeaderItem
s that this bundle provides.- Parameters:
items
-
-
getResource
Description copied from class:ResourceReference
Returns the resource.- Specified by:
getResource
in classResourceReference
- Returns:
- resource instance
-
getProvidedResources
- Specified by:
getProvidedResources
in interfaceIResourceBundle
- Returns:
- the resources that are provided (part of) this resource.
-
getDependencies
- Overrides:
getDependencies
in classResourceReference
- Returns:
- the resources this ResourceReference depends on.
-