You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@wicket.apache.org by mg...@apache.org on 2012/01/31 12:33:24 UTC

git commit: WICKET-4372 Two WicketSerializableException classes

Updated Branches:
  refs/heads/master 8a61dc2c5 -> d271d0eb7


WICKET-4372
Two WicketSerializableException classes


Project: http://git-wip-us.apache.org/repos/asf/wicket/repo
Commit: http://git-wip-us.apache.org/repos/asf/wicket/commit/d271d0eb
Tree: http://git-wip-us.apache.org/repos/asf/wicket/tree/d271d0eb
Diff: http://git-wip-us.apache.org/repos/asf/wicket/diff/d271d0eb

Branch: refs/heads/master
Commit: d271d0eb7bd5bffb7c06a5e1d8fe3da50dfe3a1e
Parents: 8a61dc2
Author: Martin Tzvetanov Grigorov <mg...@apache.org>
Authored: Tue Jan 31 13:33:20 2012 +0200
Committer: Martin Tzvetanov Grigorov <mg...@apache.org>
Committed: Tue Jan 31 13:33:20 2012 +0200

----------------------------------------------------------------------
 .../util/io/WicketSerializeableException.java      |   92 ---------------
 1 files changed, 0 insertions(+), 92 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/wicket/blob/d271d0eb/wicket-core/src/main/java/org/apache/wicket/util/io/WicketSerializeableException.java
----------------------------------------------------------------------
diff --git a/wicket-core/src/main/java/org/apache/wicket/util/io/WicketSerializeableException.java b/wicket-core/src/main/java/org/apache/wicket/util/io/WicketSerializeableException.java
deleted file mode 100644
index 84c760f..0000000
--- a/wicket-core/src/main/java/org/apache/wicket/util/io/WicketSerializeableException.java
+++ /dev/null
@@ -1,92 +0,0 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one or more
- * contributor license agreements.  See the NOTICE file distributed with
- * this work for additional information regarding copyright ownership.
- * The ASF licenses this file to You 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.apache.wicket.util.io;
-
-import java.io.NotSerializableException;
-import java.util.ArrayList;
-import java.util.List;
-
-import org.apache.wicket.util.string.AppendingStringBuffer;
-
-
-/**
- * @author jcompagner
- */
-public class WicketSerializeableException extends NotSerializableException
-{
-	private static final long serialVersionUID = 1L;
-
-	private final List<String> list;
-
-	/**
-	 * Construct.
-	 * 
-	 * @param message
-	 */
-	public WicketSerializeableException(String message)
-	{
-		super(message);
-		list = new ArrayList<String>();
-	}
-
-	/**
-	 * Construct.
-	 * 
-	 * @param message
-	 * @param cause
-	 */
-	public WicketSerializeableException(String message, Throwable cause)
-	{
-		this(message);
-		initCause(cause);
-	}
-
-	/**
-	 * @see java.lang.Throwable#getMessage()
-	 */
-	@Override
-	public String getMessage()
-	{
-		AppendingStringBuffer asb = new AppendingStringBuffer(super.getMessage());
-		if (list.size() > 0)
-		{
-			asb.append("\n");
-			for (int i = list.size(); --i >= 0;)
-			{
-				String element = list.get(i);
-				asb.append(element);
-				asb.append("->");
-			}
-			asb.setLength(asb.length() - 2);
-		}
-		asb.append("\nNOTE: if you feel Wicket is at fault with this exception").append(
-			", please report to the mailing list. You can switch to ").append(
-			"JDK based serialization by calling: ").append(
-			"org.apache.wicket.util.lang.Objects.setObjectStreamFactory(").append(
-			"new IObjectStreamFactory.DefaultObjectStreamFactory()) ").append(
-			"e.g. in the init method of your application");
-		return asb.toString();
-	}
-
-	/**
-	 * @param traceString
-	 */
-	public void addTrace(String traceString)
-	{
-		list.add(traceString);
-	}
-}