[
https://issues.apache.org/jira/browse/IO-596?focusedWorklogId=470981&page=com.atlassian.jira.plugin.system.issuetabpanels:worklog-tabpanel#worklog-470981
]
ASF GitHub Bot logged work on IO-596:
-------------------------------------
Author: ASF GitHub Bot
Created on: 15/Aug/20 03:41
Start Date: 15/Aug/20 03:41
Worklog Time Spent: 10m
Work Description: garydgregory commented on a change in pull request #72:
URL: https://github.com/apache/commons-io/pull/72#discussion_r470932614
##########
File path: src/main/java/org/apache/commons/io/CompositeIOException.java
##########
@@ -0,0 +1,44 @@
+/*
+ * 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.commons.io;
+
+import java.io.IOException;
+import java.util.List;
+
+/**
+ * Combines one or more IOExceptions into a single IOException.
+ */
+public class CompositeIOException extends IOException {
+ private static final long serialVersionUID = 1L;
+
+ private final IOException[] causes;
+
+ public CompositeIOException(final String message, final List<IOException>
causes) {
+ super(message);
+ this.causes = causes.toArray(new IOException[0]);
+ }
+
+ public CompositeIOException(final String message, final IOException...
causes) {
+ super(message);
+ this.causes = causes.clone();
+ }
+
+ public IOException[] getCauses() {
+ return causes.clone();
+ }
+}
Review comment:
Note that we have `IOExceptionList`.
----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
For queries about this service, please contact Infrastructure at:
[email protected]
Issue Time Tracking
-------------------
Worklog Id: (was: 470981)
Time Spent: 50m (was: 40m)
> Add DeleteFiles utility class for more robust file deletion strategies
> ----------------------------------------------------------------------
>
> Key: IO-596
> URL: https://issues.apache.org/jira/browse/IO-596
> Project: Commons IO
> Issue Type: New Feature
> Components: Utilities
> Reporter: Matt Sicker
> Assignee: Matt Sicker
> Priority: Major
> Time Spent: 50m
> Remaining Estimate: 0h
>
> Particularly for Windows environments where deleting files can turn into a
> hassle due to the inability to remove open files, I would like to provide a
> file deletion utility class that has the ability to retry deletions with
> exponential backoff, force override file attributes to allow for deletion,
> and deleting as much as possible while accumulating errors.
> This functionality was originally inspired by and based on functionality in
> Jenkins hudson.Util class.
--
This message was sent by Atlassian Jira
(v8.3.4#803005)