diff --git a/urlfragment-parent/urlfragment/src/main/java/org/wicketstuff/urlfragment/AsyncUrlFragmentAwarePage.java b/urlfragment-parent/urlfragment/src/main/java/org/wicketstuff/urlfragment/AsyncUrlFragmentAwarePage.java index a2ae5d0613..2e9ce164fc 100644 --- a/urlfragment-parent/urlfragment/src/main/java/org/wicketstuff/urlfragment/AsyncUrlFragmentAwarePage.java +++ b/urlfragment-parent/urlfragment/src/main/java/org/wicketstuff/urlfragment/AsyncUrlFragmentAwarePage.java @@ -43,7 +43,7 @@ * @author Martin Knopf * */ -public abstract class AsyncUrlFragmentAwarePage extends WebPage implements IBookmarkableComponent +public abstract class AsyncUrlFragmentAwarePage extends WebPage { private static final long serialVersionUID = 1L; private transient AjaxRequestTarget target = null; @@ -115,36 +115,6 @@ protected Map getOptions() protected abstract void onParameterArrival(IRequestParameters requestParameters, AjaxRequestTarget target); - @Override - @Deprecated - public void setFragmentParameter(String parameterName, Object parameterValue) - { - if (this.target != null && parameterName != "" && parameterValue != "") - { - urlFragment().putParameter(parameterName, parameterValue); - } - } - - @Override - @Deprecated - public void addFragmentParameter(String parameterName, Object parameterValue, String delimiter) - { - if (this.target != null && parameterName != "" && parameterValue != "") - { - urlFragment().putParameter(parameterName, parameterValue, delimiter); - } - } - - @Override - @Deprecated - public void removeFragmentParameter(String parameterName) - { - if (this.target != null && parameterName != "") - { - urlFragment().removeParameter(parameterName); - } - } - /** * Returns a {@link UrlFragment} connected to the current {@link AjaxRequestTarget}. Use the * {@link UrlFragment} to update the URL fragment in the browser after the current AJAX event. diff --git a/urlfragment-parent/urlfragment/src/main/java/org/wicketstuff/urlfragment/AsyncUrlFragmentAwarePanel.java b/urlfragment-parent/urlfragment/src/main/java/org/wicketstuff/urlfragment/AsyncUrlFragmentAwarePanel.java index 1ad2165e1e..e4af047813 100644 --- a/urlfragment-parent/urlfragment/src/main/java/org/wicketstuff/urlfragment/AsyncUrlFragmentAwarePanel.java +++ b/urlfragment-parent/urlfragment/src/main/java/org/wicketstuff/urlfragment/AsyncUrlFragmentAwarePanel.java @@ -18,7 +18,6 @@ import java.util.Map; import org.apache.wicket.ajax.AjaxRequestTarget; -import org.apache.wicket.markup.head.IHeaderResponse; import org.apache.wicket.markup.html.panel.Panel; import org.apache.wicket.model.IModel; import org.apache.wicket.request.IRequestParameters; @@ -42,7 +41,7 @@ * @author Martin Knopf * */ -public abstract class AsyncUrlFragmentAwarePanel extends Panel implements IBookmarkableComponent +public abstract class AsyncUrlFragmentAwarePanel extends Panel { private static final long serialVersionUID = 1L; private transient AjaxRequestTarget target = null; @@ -110,43 +109,6 @@ protected Map getOptions() protected abstract void onParameterIncome(IRequestParameters requestParameters, AjaxRequestTarget target); - @Override - @Deprecated - public void setFragmentParameter(String parameterName, Object parameterValue) - { - if (this.target != null && parameterName != "" && parameterValue != "") - { - urlFragment().putParameter(parameterName, parameterValue); - } - } - - @Override - @Deprecated - public void addFragmentParameter(String parameterName, Object parameterValue, String delimiter) - { - if (this.target != null && parameterName != "" && parameterValue != "") - { - urlFragment().putParameter(parameterName, parameterValue, delimiter); - } - } - - @Override - @Deprecated - public void removeFragmentParameter(String parameterName) - { - if (this.target != null && parameterName != "") - { - urlFragment().removeParameter(parameterName); - } - } - - @Override - public void renderHead(IHeaderResponse response) - { - super.renderHead(response); - response.render(UrlParametersReceivingBehavior.JS_REF); - } - /** * Returns a {@link UrlFragment} connected to the current {@link AjaxRequestTarget}. Use the * {@link UrlFragment} to update the URL fragment in the browser after the current AJAX event. diff --git a/urlfragment-parent/urlfragment/src/main/java/org/wicketstuff/urlfragment/BookmarkableAjaxButton.java b/urlfragment-parent/urlfragment/src/main/java/org/wicketstuff/urlfragment/BookmarkableAjaxButton.java index f2e927fcd1..7c9da969a5 100644 --- a/urlfragment-parent/urlfragment/src/main/java/org/wicketstuff/urlfragment/BookmarkableAjaxButton.java +++ b/urlfragment-parent/urlfragment/src/main/java/org/wicketstuff/urlfragment/BookmarkableAjaxButton.java @@ -29,7 +29,7 @@ * * @author Martin Knopf */ -public abstract class BookmarkableAjaxButton extends AjaxButton implements IBookmarkableComponent +public abstract class BookmarkableAjaxButton extends AjaxButton { private static final long serialVersionUID = 1L; private transient AjaxRequestTarget target = null; @@ -84,36 +84,6 @@ protected void onError(AjaxRequestTarget target) */ protected abstract void onBookmarkableError(AjaxRequestTarget target); - @Override - @Deprecated - public void setFragmentParameter(String parameterName, Object parameterValue) - { - if (this.target != null && parameterName != "" && parameterValue != "") - { - urlFragment().putParameter(parameterName, parameterValue); - } - } - - @Override - @Deprecated - public void addFragmentParameter(String parameterName, Object parameterValue, String delimiter) - { - if (this.target != null && parameterName != "" && parameterValue != "") - { - urlFragment().putParameter(parameterName, parameterValue, delimiter); - } - } - - @Override - @Deprecated - public void removeFragmentParameter(String parameterName) - { - if (this.target != null && parameterName != "") - { - urlFragment().removeParameter(parameterName); - } - } - /** * Returns a {@link UrlFragment} connected to the current {@link AjaxRequestTarget}. Use the * {@link UrlFragment} to update the URL fragment in the browser after the current AJAX event. diff --git a/urlfragment-parent/urlfragment/src/main/java/org/wicketstuff/urlfragment/BookmarkableAjaxLink.java b/urlfragment-parent/urlfragment/src/main/java/org/wicketstuff/urlfragment/BookmarkableAjaxLink.java index 2eb3f9ff1f..2b7f4e548d 100644 --- a/urlfragment-parent/urlfragment/src/main/java/org/wicketstuff/urlfragment/BookmarkableAjaxLink.java +++ b/urlfragment-parent/urlfragment/src/main/java/org/wicketstuff/urlfragment/BookmarkableAjaxLink.java @@ -31,7 +31,7 @@ * * @param the type of Model object */ -public abstract class BookmarkableAjaxLink extends AjaxLink implements IBookmarkableComponent +public abstract class BookmarkableAjaxLink extends AjaxLink { private static final long serialVersionUID = 1L; @@ -114,36 +114,6 @@ public void onClick(AjaxRequestTarget target) */ public abstract void onBookmarkableClick(AjaxRequestTarget target); - @Override - @Deprecated - public void setFragmentParameter(String parameterName, Object parameterValue) - { - if (this.target != null && parameterName != "" && parameterValue != "") - { - urlFragment().putParameter(parameterName, parameterValue); - } - } - - @Override - @Deprecated - public void addFragmentParameter(String parameterName, Object parameterValue, String delimiter) - { - if (this.target != null && parameterName != "" && parameterValue != "") - { - urlFragment().putParameter(parameterName, parameterValue, delimiter); - } - } - - @Override - @Deprecated - public void removeFragmentParameter(String parameterName) - { - if (this.target != null && parameterName != "") - { - urlFragment().removeParameter(parameterName); - } - } - /** * Returns a {@link UrlFragment} connected to the current {@link AjaxRequestTarget}. Use the * {@link UrlFragment} to update the URL fragment in the browser after the current AJAX event. diff --git a/urlfragment-parent/urlfragment/src/main/java/org/wicketstuff/urlfragment/IBookmarkableComponent.java b/urlfragment-parent/urlfragment/src/main/java/org/wicketstuff/urlfragment/IBookmarkableComponent.java deleted file mode 100644 index c7f367609c..0000000000 --- a/urlfragment-parent/urlfragment/src/main/java/org/wicketstuff/urlfragment/IBookmarkableComponent.java +++ /dev/null @@ -1,74 +0,0 @@ -/* Copyright (c) 2013 Martin Knopf - * - * Licensed under the MIT license; - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://opensource.org/licenses/MIT - * - * 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.wicketstuff.urlfragment; - -import org.apache.wicket.ajax.AjaxRequestTarget; - -public interface IBookmarkableComponent -{ - /** - * Sets the given URL fragment parameter by adding a JavaScript to the current - * {@link AjaxRequestTarget}. - *

- * The parameter will be overwritten if it already exists. - *

- * - * @param parameterName - * the name of your URL fragment parameter to set - * @param parameterValue - * the value of your URL fragment parameter to set - */ - @Deprecated - void setFragmentParameter(String parameterName, Object parameterValue); - - /** - *

- * Use the following instead: - * {@code urlFragment().addParameter(parameterName, parameterValue, delimiter);} - *

- * Sets the given URL fragment parameter by adding a JavaScript to the current - * {@link AjaxRequestTarget}. - *

- * The parameter will be created if it doesn't exists yet. - *

- *

- * The value will be appended with the specified delimiter if the parameter already exists. - *

- * - * @param parameterName - * the name of your URL fragment parameter to set - * @param parameterValue - * the value of your URL fragment parameter to set - * @param delimiter - * the delimiter the given value will be appended with if the given parameter already - * exists - */ - @Deprecated - void addFragmentParameter(String parameterName, Object parameterValue, String delimiter); - - /** - *

- * Use the following instead: {@code urlFragment().removeParameter(parameterName);} - * - *

- * Removes the given URL fragment parameter by adding a JavaScript to the current - * {@link AjaxRequestTarget}. - * - * @param parameterName - * the name of your URL fragment parameter to set - */ - @Deprecated - void removeFragmentParameter(String parameterName); -}