X-Git-Url: http://wamblee.org/gitweb/?a=blobdiff_plain;ds=inline;f=wicket%2Fcomponents%2Fsrc%2Fmain%2Fjava%2Forg%2Fwamblee%2Fwicket%2Fbehavior%2FDisableCachingBehavior.java;fp=wicket%2Fcomponents%2Fsrc%2Fmain%2Fjava%2Forg%2Fwamblee%2Fwicket%2Fbehavior%2FDisableCachingBehavior.java;h=0000000000000000000000000000000000000000;hb=4fe80b8d110c4a54793f66d07d80965649e9ab7f;hp=18956a6e0e617fbac6ed04e0a88933fabbb2675f;hpb=e897c0b96075ff833db4bb42c6bb267275376c7c;p=utils diff --git a/wicket/components/src/main/java/org/wamblee/wicket/behavior/DisableCachingBehavior.java b/wicket/components/src/main/java/org/wamblee/wicket/behavior/DisableCachingBehavior.java deleted file mode 100644 index 18956a6e..00000000 --- a/wicket/components/src/main/java/org/wamblee/wicket/behavior/DisableCachingBehavior.java +++ /dev/null @@ -1,45 +0,0 @@ -/* - * Copyright 2005-2010 the original author or authors. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ -package org.wamblee.wicket.behavior; - -import org.apache.wicket.markup.html.WebPage; -import org.apache.wicket.protocol.http.WebResponse; - -/** - *

- * Behavior to disable browser caching. This also means that the page - * automatically expires the first time after it is rendered. - *

- * - *

- * Important: To make sure that form data cannot be submitted twice for - * the same data using the back button, it is still necessary to explicitly call - * getPage().getPageMap().remove(getPage()); - * in the onSubmit callback of the form. - *

- * - * @author Erik Brakkee - * - */ -public class DisableCachingBehavior extends ExpirePageImmediatelyBehavior { - - @Override - public void setHeaders(WebPage aPage, WebResponse aResponse) { - aResponse.setHeader("Pragma", "no-cache"); - aResponse.setHeader("Cache-Control", - "no-cache, max-age=0, must-revalidate, no-store"); - } -}