You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@harmony.apache.org by te...@apache.org on 2007/06/13 09:44:25 UTC

svn commit: r546764 - in /harmony/enhanced/classlib/branches/java6/modules/archive/src: main/java/java/util/zip/ test/java/org/apache/harmony/archive/tests/java/util/zip/ test/resources/serialization/ test/resources/serialization/org/ test/resources/se...

Author: tellison
Date: Wed Jun 13 00:44:23 2007
New Revision: 546764

URL: http://svn.apache.org/viewvc?view=rev&rev=546764
Log:
Apply patch for HARMONY-4133 ([classlib][luni][java6] New class java.util.zip.ZipError for java6)

Added:
    harmony/enhanced/classlib/branches/java6/modules/archive/src/main/java/java/util/zip/ZipError.java   (with props)
    harmony/enhanced/classlib/branches/java6/modules/archive/src/test/java/org/apache/harmony/archive/tests/java/util/zip/ZipErrorTest.java   (with props)
    harmony/enhanced/classlib/branches/java6/modules/archive/src/test/resources/serialization/
    harmony/enhanced/classlib/branches/java6/modules/archive/src/test/resources/serialization/org/
    harmony/enhanced/classlib/branches/java6/modules/archive/src/test/resources/serialization/org/apache/
    harmony/enhanced/classlib/branches/java6/modules/archive/src/test/resources/serialization/org/apache/harmony/
    harmony/enhanced/classlib/branches/java6/modules/archive/src/test/resources/serialization/org/apache/harmony/archive/
    harmony/enhanced/classlib/branches/java6/modules/archive/src/test/resources/serialization/org/apache/harmony/archive/tests/
    harmony/enhanced/classlib/branches/java6/modules/archive/src/test/resources/serialization/org/apache/harmony/archive/tests/java/
    harmony/enhanced/classlib/branches/java6/modules/archive/src/test/resources/serialization/org/apache/harmony/archive/tests/java/util/
    harmony/enhanced/classlib/branches/java6/modules/archive/src/test/resources/serialization/org/apache/harmony/archive/tests/java/util/zip/
    harmony/enhanced/classlib/branches/java6/modules/archive/src/test/resources/serialization/org/apache/harmony/archive/tests/java/util/zip/ZipErrorTest.golden.ser   (with props)

Added: harmony/enhanced/classlib/branches/java6/modules/archive/src/main/java/java/util/zip/ZipError.java
URL: http://svn.apache.org/viewvc/harmony/enhanced/classlib/branches/java6/modules/archive/src/main/java/java/util/zip/ZipError.java?view=auto&rev=546764
==============================================================================
--- harmony/enhanced/classlib/branches/java6/modules/archive/src/main/java/java/util/zip/ZipError.java (added)
+++ harmony/enhanced/classlib/branches/java6/modules/archive/src/main/java/java/util/zip/ZipError.java Wed Jun 13 00:44:23 2007
@@ -0,0 +1,36 @@
+/* 
+ * 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 java.util.zip;
+
+/**
+ * This error is thrown when an unrecoverable ZIP error has occurred.
+ */
+public class ZipError extends InternalError {
+
+    private static final long serialVersionUID = 853973422266861979L;
+
+    /**
+     * the Constructor
+     * 
+     * @param s
+     *            the message
+     */
+    public ZipError(String s) {
+        super(s);
+    }
+}

Propchange: harmony/enhanced/classlib/branches/java6/modules/archive/src/main/java/java/util/zip/ZipError.java
------------------------------------------------------------------------------
    svn:eol-style = native

Added: harmony/enhanced/classlib/branches/java6/modules/archive/src/test/java/org/apache/harmony/archive/tests/java/util/zip/ZipErrorTest.java
URL: http://svn.apache.org/viewvc/harmony/enhanced/classlib/branches/java6/modules/archive/src/test/java/org/apache/harmony/archive/tests/java/util/zip/ZipErrorTest.java?view=auto&rev=546764
==============================================================================
--- harmony/enhanced/classlib/branches/java6/modules/archive/src/test/java/org/apache/harmony/archive/tests/java/util/zip/ZipErrorTest.java (added)
+++ harmony/enhanced/classlib/branches/java6/modules/archive/src/test/java/org/apache/harmony/archive/tests/java/util/zip/ZipErrorTest.java Wed Jun 13 00:44:23 2007
@@ -0,0 +1,50 @@
+/* 
+ * 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.harmony.archive.tests.java.util.zip;
+
+import java.io.IOException;
+import java.util.zip.ZipError;
+import org.apache.harmony.testframework.serialization.SerializationTest;
+import junit.framework.TestCase;
+
+public class ZipErrorTest extends TestCase {
+
+    /**
+     * @tests {@link java.util.zip.ZipError#ZipError(String)}
+     */
+    public void test_constructor() {
+        ZipError error = new ZipError("ZipError");
+        assertEquals("ZipError", error.getMessage());
+    }
+    
+    /**
+     * @tests java.util.zip.ZipError#Serialization()
+     */
+    public void test_serialization() throws Exception {
+        ZipError error = new ZipError("serialization test");
+        SerializationTest.verifySelf(error);
+    }
+    
+    /**
+     * @tests serialization/deserialization compatibility with RI.
+     */
+    public void testSerializationCompatibility() throws Exception {
+        ZipError error = new ZipError("serialization test");
+        SerializationTest.verifyGolden(this, error);
+    }
+
+}

Propchange: harmony/enhanced/classlib/branches/java6/modules/archive/src/test/java/org/apache/harmony/archive/tests/java/util/zip/ZipErrorTest.java
------------------------------------------------------------------------------
    svn:eol-style = native

Added: harmony/enhanced/classlib/branches/java6/modules/archive/src/test/resources/serialization/org/apache/harmony/archive/tests/java/util/zip/ZipErrorTest.golden.ser
URL: http://svn.apache.org/viewvc/harmony/enhanced/classlib/branches/java6/modules/archive/src/test/resources/serialization/org/apache/harmony/archive/tests/java/util/zip/ZipErrorTest.golden.ser?view=auto&rev=546764
==============================================================================
Binary file - no diff available.

Propchange: harmony/enhanced/classlib/branches/java6/modules/archive/src/test/resources/serialization/org/apache/harmony/archive/tests/java/util/zip/ZipErrorTest.golden.ser
------------------------------------------------------------------------------
    svn:mime-type = application/octet-stream