001/*
002 * Licensed to the Apache Software Foundation (ASF) under one or more
003 * contributor license agreements.  See the NOTICE file distributed with
004 * this work for additional information regarding copyright ownership.
005 * The ASF licenses this file to You under the Apache License, Version 2.0
006 * (the "License"); you may not use this file except in compliance with
007 * the License.  You may obtain a copy of the License at
008 *
009 *      http://www.apache.org/licenses/LICENSE-2.0
010 *
011 * Unless required by applicable law or agreed to in writing, software
012 * distributed under the License is distributed on an "AS IS" BASIS,
013 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
014 * See the License for the specific language governing permissions and
015 * limitations under the License.
016 */
017package org.apache.wicket.resource.bundles;
018
019import java.util.List;
020
021import org.apache.wicket.markup.head.HeaderItem;
022import org.apache.wicket.request.resource.ResourceReference;
023
024/**
025 * An extension of ResourceBundleReference that is used especially
026 * for resource replacements
027 *
028 * @see org.apache.wicket.protocol.http.WebApplication#addResourceReplacement(org.apache.wicket.request.resource.CssResourceReference, org.apache.wicket.request.resource.ResourceReference)
029 * @see org.apache.wicket.protocol.http.WebApplication#addResourceReplacement(org.apache.wicket.request.resource.JavaScriptResourceReference, org.apache.wicket.request.resource.ResourceReference)
030 * @since 6.13
031 */
032public class ReplacementResourceBundleReference extends ResourceBundleReference
033{
034        private static final long serialVersionUID = 1L;
035
036        /**
037         * Creates a new bundle reference from the given reference.
038         *
039         * @param bundleRef
040         */
041        public ReplacementResourceBundleReference(ResourceReference bundleRef)
042        {
043                super(bundleRef);
044        }
045        
046        /**
047         * Returns the dependencies of the replacing resource reference.
048         * 
049         * @return the dependencies of the replacing resource reference
050         */
051        @Override
052        public List<HeaderItem> getDependencies() 
053        {
054                return getBundleReference().getDependencies();
055        }
056}