Search in sources :

Example 1 with HeaderContributorListenerCollection

use of org.apache.wicket.application.HeaderContributorListenerCollection in project wicket by apache.

the class AbstractHeaderRenderStrategy method renderApplicationLevelHeaders.

/**
 * Render the application level headers
 *
 * @param headerContainer
 */
protected final void renderApplicationLevelHeaders(final HtmlHeaderContainer headerContainer) {
    Args.notNull(headerContainer, "headerContainer");
    if (Application.exists()) {
        HeaderContributorListenerCollection headerContributorListenerCollection = Application.get().getHeaderContributorListeners();
        IHeaderResponse headerResponse = headerContainer.getHeaderResponse();
        for (IHeaderContributor listener : headerContributorListenerCollection) {
            listener.renderHead(headerResponse);
        }
    }
}
Also used : IHeaderContributor(org.apache.wicket.markup.html.IHeaderContributor) HeaderContributorListenerCollection(org.apache.wicket.application.HeaderContributorListenerCollection) IHeaderResponse(org.apache.wicket.markup.head.IHeaderResponse)

Aggregations

HeaderContributorListenerCollection (org.apache.wicket.application.HeaderContributorListenerCollection)1 IHeaderResponse (org.apache.wicket.markup.head.IHeaderResponse)1 IHeaderContributor (org.apache.wicket.markup.html.IHeaderContributor)1