346 lines
15 KiB
HTML
346 lines
15 KiB
HTML
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
|
|
<!-- NewPage -->
|
|
<html lang="en">
|
|
<head>
|
|
<!-- Generated by javadoc -->
|
|
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1">
|
|
<title>org.apache.commons.io (Apache Commons IO 2.11.0 API)</title>
|
|
<link rel="stylesheet" type="text/css" href="../../../../stylesheet.css" title="Style">
|
|
<script type="text/javascript" src="../../../../script.js"></script>
|
|
</head>
|
|
<body>
|
|
<script type="text/javascript"><!--
|
|
try {
|
|
if (location.href.indexOf('is-external=true') == -1) {
|
|
parent.document.title="org.apache.commons.io (Apache Commons IO 2.11.0 API)";
|
|
}
|
|
}
|
|
catch(err) {
|
|
}
|
|
//-->
|
|
</script>
|
|
<noscript>
|
|
<div>JavaScript is disabled on your browser.</div>
|
|
</noscript>
|
|
<!-- ========= START OF TOP NAVBAR ======= -->
|
|
<div class="topNav"><a name="navbar.top">
|
|
<!-- -->
|
|
</a>
|
|
<div class="skipNav"><a href="#skip.navbar.top" title="Skip navigation links">Skip navigation links</a></div>
|
|
<a name="navbar.top.firstrow">
|
|
<!-- -->
|
|
</a>
|
|
<ul class="navList" title="Navigation">
|
|
<li><a href="../../../../overview-summary.html">Overview</a></li>
|
|
<li class="navBarCell1Rev">Package</li>
|
|
<li>Class</li>
|
|
<li><a href="package-use.html">Use</a></li>
|
|
<li><a href="package-tree.html">Tree</a></li>
|
|
<li><a href="../../../../deprecated-list.html">Deprecated</a></li>
|
|
<li><a href="../../../../index-all.html">Index</a></li>
|
|
<li><a href="../../../../help-doc.html">Help</a></li>
|
|
</ul>
|
|
</div>
|
|
<div class="subNav">
|
|
<ul class="navList">
|
|
<li>Prev Package</li>
|
|
<li><a href="../../../../org/apache/commons/io/comparator/package-summary.html">Next Package</a></li>
|
|
</ul>
|
|
<ul class="navList">
|
|
<li><a href="../../../../index.html?org/apache/commons/io/package-summary.html" target="_top">Frames</a></li>
|
|
<li><a href="package-summary.html" target="_top">No Frames</a></li>
|
|
</ul>
|
|
<ul class="navList" id="allclasses_navbar_top">
|
|
<li><a href="../../../../allclasses-noframe.html">All Classes</a></li>
|
|
</ul>
|
|
<div>
|
|
<script type="text/javascript"><!--
|
|
allClassesLink = document.getElementById("allclasses_navbar_top");
|
|
if(window==top) {
|
|
allClassesLink.style.display = "block";
|
|
}
|
|
else {
|
|
allClassesLink.style.display = "none";
|
|
}
|
|
//-->
|
|
</script>
|
|
</div>
|
|
<a name="skip.navbar.top">
|
|
<!-- -->
|
|
</a></div>
|
|
<!-- ========= END OF TOP NAVBAR ========= -->
|
|
<div class="header">
|
|
<h1 title="Package" class="title">Package org.apache.commons.io</h1>
|
|
<div class="docSummary">
|
|
<div class="block">
|
|
This package defines utility classes for working with streams, readers,
|
|
writers and files.</div>
|
|
</div>
|
|
<p>See: <a href="#package.description">Description</a></p>
|
|
</div>
|
|
<div class="contentContainer">
|
|
<ul class="blockList">
|
|
<li class="blockList">
|
|
<table class="typeSummary" border="0" cellpadding="3" cellspacing="0" summary="Class Summary table, listing classes, and an explanation">
|
|
<caption><span>Class Summary</span><span class="tabEnd"> </span></caption>
|
|
<tr>
|
|
<th class="colFirst" scope="col">Class</th>
|
|
<th class="colLast" scope="col">Description</th>
|
|
</tr>
|
|
<tbody>
|
|
<tr class="altColor">
|
|
<td class="colFirst"><a href="../../../../org/apache/commons/io/ByteOrderMark.html" title="class in org.apache.commons.io">ByteOrderMark</a></td>
|
|
<td class="colLast">
|
|
<div class="block">Byte Order Mark (BOM) representation - see <a href="../../../../org/apache/commons/io/input/BOMInputStream.html" title="class in org.apache.commons.io.input"><code>BOMInputStream</code></a>.</div>
|
|
</td>
|
|
</tr>
|
|
<tr class="rowColor">
|
|
<td class="colFirst"><a href="../../../../org/apache/commons/io/ByteOrderParser.html" title="class in org.apache.commons.io">ByteOrderParser</a></td>
|
|
<td class="colLast">
|
|
<div class="block">Converts Strings to <a href="https://docs.oracle.com/javase/7/docs/api/java/nio/ByteOrder.html?is-external=true" title="class or interface in java.nio"><code>ByteOrder</code></a> instances.</div>
|
|
</td>
|
|
</tr>
|
|
<tr class="altColor">
|
|
<td class="colFirst"><a href="../../../../org/apache/commons/io/Charsets.html" title="class in org.apache.commons.io">Charsets</a></td>
|
|
<td class="colLast">
|
|
<div class="block">Charsets required of every implementation of the Java platform.</div>
|
|
</td>
|
|
</tr>
|
|
<tr class="rowColor">
|
|
<td class="colFirst"><a href="../../../../org/apache/commons/io/CopyUtils.html" title="class in org.apache.commons.io">CopyUtils</a></td>
|
|
<td class="colLast">Deprecated
|
|
<div class="block"><span class="deprecationComment">Use IOUtils.</span></div>
|
|
</td>
|
|
</tr>
|
|
<tr class="altColor">
|
|
<td class="colFirst"><a href="../../../../org/apache/commons/io/DirectoryWalker.html" title="class in org.apache.commons.io">DirectoryWalker</a><T></td>
|
|
<td class="colLast">Deprecated
|
|
<div class="block"><span class="deprecationComment">Apache Commons IO no longer uses this class.</span></div>
|
|
</td>
|
|
</tr>
|
|
<tr class="rowColor">
|
|
<td class="colFirst"><a href="../../../../org/apache/commons/io/EndianUtils.html" title="class in org.apache.commons.io">EndianUtils</a></td>
|
|
<td class="colLast">
|
|
<div class="block">Utility code for dealing with different endian systems.</div>
|
|
</td>
|
|
</tr>
|
|
<tr class="altColor">
|
|
<td class="colFirst"><a href="../../../../org/apache/commons/io/FileCleaner.html" title="class in org.apache.commons.io">FileCleaner</a></td>
|
|
<td class="colLast">Deprecated
|
|
<div class="block"><span class="deprecationComment">Use <a href="../../../../org/apache/commons/io/FileCleaningTracker.html" title="class in org.apache.commons.io"><code>FileCleaningTracker</code></a></span></div>
|
|
</td>
|
|
</tr>
|
|
<tr class="rowColor">
|
|
<td class="colFirst"><a href="../../../../org/apache/commons/io/FileCleaningTracker.html" title="class in org.apache.commons.io">FileCleaningTracker</a></td>
|
|
<td class="colLast">
|
|
<div class="block">Keeps track of files awaiting deletion, and deletes them when an associated
|
|
marker object is reclaimed by the garbage collector.</div>
|
|
</td>
|
|
</tr>
|
|
<tr class="altColor">
|
|
<td class="colFirst"><a href="../../../../org/apache/commons/io/FileDeleteStrategy.html" title="class in org.apache.commons.io">FileDeleteStrategy</a></td>
|
|
<td class="colLast">
|
|
<div class="block">Strategy for deleting files.</div>
|
|
</td>
|
|
</tr>
|
|
<tr class="rowColor">
|
|
<td class="colFirst"><a href="../../../../org/apache/commons/io/FilenameUtils.html" title="class in org.apache.commons.io">FilenameUtils</a></td>
|
|
<td class="colLast">
|
|
<div class="block">General file name and file path manipulation utilities.</div>
|
|
</td>
|
|
</tr>
|
|
<tr class="altColor">
|
|
<td class="colFirst"><a href="../../../../org/apache/commons/io/FileSystemUtils.html" title="class in org.apache.commons.io">FileSystemUtils</a></td>
|
|
<td class="colLast">Deprecated
|
|
<div class="block"><span class="deprecationComment">As of 2.6 deprecated without replacement.</span></div>
|
|
</td>
|
|
</tr>
|
|
<tr class="rowColor">
|
|
<td class="colFirst"><a href="../../../../org/apache/commons/io/FileUtils.html" title="class in org.apache.commons.io">FileUtils</a></td>
|
|
<td class="colLast">
|
|
<div class="block">General file manipulation utilities.</div>
|
|
</td>
|
|
</tr>
|
|
<tr class="altColor">
|
|
<td class="colFirst"><a href="../../../../org/apache/commons/io/HexDump.html" title="class in org.apache.commons.io">HexDump</a></td>
|
|
<td class="colLast">
|
|
<div class="block">Dumps data in hexadecimal format.</div>
|
|
</td>
|
|
</tr>
|
|
<tr class="rowColor">
|
|
<td class="colFirst"><a href="../../../../org/apache/commons/io/IOUtils.html" title="class in org.apache.commons.io">IOUtils</a></td>
|
|
<td class="colLast">
|
|
<div class="block">General IO stream manipulation utilities.</div>
|
|
</td>
|
|
</tr>
|
|
<tr class="altColor">
|
|
<td class="colFirst"><a href="../../../../org/apache/commons/io/LineIterator.html" title="class in org.apache.commons.io">LineIterator</a></td>
|
|
<td class="colLast">
|
|
<div class="block">An Iterator over the lines in a <code>Reader</code>.</div>
|
|
</td>
|
|
</tr>
|
|
</tbody>
|
|
</table>
|
|
</li>
|
|
<li class="blockList">
|
|
<table class="typeSummary" border="0" cellpadding="3" cellspacing="0" summary="Enum Summary table, listing enums, and an explanation">
|
|
<caption><span>Enum Summary</span><span class="tabEnd"> </span></caption>
|
|
<tr>
|
|
<th class="colFirst" scope="col">Enum</th>
|
|
<th class="colLast" scope="col">Description</th>
|
|
</tr>
|
|
<tbody>
|
|
<tr class="altColor">
|
|
<td class="colFirst"><a href="../../../../org/apache/commons/io/FileSystem.html" title="enum in org.apache.commons.io">FileSystem</a></td>
|
|
<td class="colLast">
|
|
<div class="block">Abstracts an OS' file system details, currently supporting the single use case of converting a file name String to a
|
|
legal file name with <a href="../../../../org/apache/commons/io/FileSystem.html#toLegalFileName-java.lang.String-char-"><code>FileSystem.toLegalFileName(String, char)</code></a>.</div>
|
|
</td>
|
|
</tr>
|
|
<tr class="rowColor">
|
|
<td class="colFirst"><a href="../../../../org/apache/commons/io/IOCase.html" title="enum in org.apache.commons.io">IOCase</a></td>
|
|
<td class="colLast">
|
|
<div class="block">Enumeration of IO case sensitivity.</div>
|
|
</td>
|
|
</tr>
|
|
<tr class="altColor">
|
|
<td class="colFirst"><a href="../../../../org/apache/commons/io/StandardLineSeparator.html" title="enum in org.apache.commons.io">StandardLineSeparator</a></td>
|
|
<td class="colLast">
|
|
<div class="block">Enumerates standard line separators: <a href="../../../../org/apache/commons/io/StandardLineSeparator.html#CR"><code>StandardLineSeparator.CR</code></a>, <a href="../../../../org/apache/commons/io/StandardLineSeparator.html#CRLF"><code>StandardLineSeparator.CRLF</code></a>, <a href="../../../../org/apache/commons/io/StandardLineSeparator.html#LF"><code>StandardLineSeparator.LF</code></a>.</div>
|
|
</td>
|
|
</tr>
|
|
</tbody>
|
|
</table>
|
|
</li>
|
|
<li class="blockList">
|
|
<table class="typeSummary" border="0" cellpadding="3" cellspacing="0" summary="Exception Summary table, listing exceptions, and an explanation">
|
|
<caption><span>Exception Summary</span><span class="tabEnd"> </span></caption>
|
|
<tr>
|
|
<th class="colFirst" scope="col">Exception</th>
|
|
<th class="colLast" scope="col">Description</th>
|
|
</tr>
|
|
<tbody>
|
|
<tr class="altColor">
|
|
<td class="colFirst"><a href="../../../../org/apache/commons/io/DirectoryWalker.CancelException.html" title="class in org.apache.commons.io">DirectoryWalker.CancelException</a></td>
|
|
<td class="colLast">
|
|
<div class="block">CancelException is thrown in DirectoryWalker to cancel the current
|
|
processing.</div>
|
|
</td>
|
|
</tr>
|
|
<tr class="rowColor">
|
|
<td class="colFirst"><a href="../../../../org/apache/commons/io/FileExistsException.html" title="class in org.apache.commons.io">FileExistsException</a></td>
|
|
<td class="colLast">
|
|
<div class="block">Indicates that a file already exists.</div>
|
|
</td>
|
|
</tr>
|
|
<tr class="altColor">
|
|
<td class="colFirst"><a href="../../../../org/apache/commons/io/IOExceptionList.html" title="class in org.apache.commons.io">IOExceptionList</a></td>
|
|
<td class="colLast">
|
|
<div class="block">A IOException based on a list of Throwable causes.</div>
|
|
</td>
|
|
</tr>
|
|
<tr class="rowColor">
|
|
<td class="colFirst"><a href="../../../../org/apache/commons/io/IOExceptionWithCause.html" title="class in org.apache.commons.io">IOExceptionWithCause</a></td>
|
|
<td class="colLast">Deprecated
|
|
<div class="block"><span class="deprecationComment">(since 2.5) use <a href="https://docs.oracle.com/javase/7/docs/api/java/io/IOException.html?is-external=true" title="class or interface in java.io"><code>IOException</code></a> instead</span></div>
|
|
</td>
|
|
</tr>
|
|
<tr class="altColor">
|
|
<td class="colFirst"><a href="../../../../org/apache/commons/io/IOIndexedException.html" title="class in org.apache.commons.io">IOIndexedException</a></td>
|
|
<td class="colLast">
|
|
<div class="block">A IOException associated with a source index.</div>
|
|
</td>
|
|
</tr>
|
|
<tr class="rowColor">
|
|
<td class="colFirst"><a href="../../../../org/apache/commons/io/TaggedIOException.html" title="class in org.apache.commons.io">TaggedIOException</a></td>
|
|
<td class="colLast">
|
|
<div class="block">An <a href="https://docs.oracle.com/javase/7/docs/api/java/io/IOException.html?is-external=true" title="class or interface in java.io"><code>IOException</code></a> decorator that adds a serializable tag to the
|
|
wrapped exception.</div>
|
|
</td>
|
|
</tr>
|
|
</tbody>
|
|
</table>
|
|
</li>
|
|
</ul>
|
|
<a name="package.description">
|
|
<!-- -->
|
|
</a>
|
|
<h2 title="Package org.apache.commons.io Description">Package org.apache.commons.io Description</h2>
|
|
<div class="block"><p>
|
|
This package defines utility classes for working with streams, readers,
|
|
writers and files. The most commonly used classes are described here:
|
|
</p>
|
|
<p>
|
|
<b>IOUtils</b> is the most frequently used class.
|
|
It provides operations to read, write, copy and close streams.
|
|
</p>
|
|
<p>
|
|
<b>FileUtils</b> provides operations based around the JDK File class.
|
|
These include reading, writing, copying, comparing and deleting.
|
|
</p>
|
|
<p>
|
|
<b>FilenameUtils</b> provides utilities based on filenames.
|
|
This utility class manipulates filenames without using File objects.
|
|
It aims to simplify the transition between Windows and Unix.
|
|
Before using this class however, you should consider whether you should
|
|
be using File objects.
|
|
</p>
|
|
<p>
|
|
<b>FileSystemUtils</b> allows access to the filing system in ways the JDK
|
|
does not support. At present this allows you to get the free space on a drive.
|
|
</p>
|
|
<p>
|
|
<b>EndianUtils</b> swaps data between Big-Endian and Little-Endian formats.
|
|
</p></div>
|
|
</div>
|
|
<!-- ======= START OF BOTTOM NAVBAR ====== -->
|
|
<div class="bottomNav"><a name="navbar.bottom">
|
|
<!-- -->
|
|
</a>
|
|
<div class="skipNav"><a href="#skip.navbar.bottom" title="Skip navigation links">Skip navigation links</a></div>
|
|
<a name="navbar.bottom.firstrow">
|
|
<!-- -->
|
|
</a>
|
|
<ul class="navList" title="Navigation">
|
|
<li><a href="../../../../overview-summary.html">Overview</a></li>
|
|
<li class="navBarCell1Rev">Package</li>
|
|
<li>Class</li>
|
|
<li><a href="package-use.html">Use</a></li>
|
|
<li><a href="package-tree.html">Tree</a></li>
|
|
<li><a href="../../../../deprecated-list.html">Deprecated</a></li>
|
|
<li><a href="../../../../index-all.html">Index</a></li>
|
|
<li><a href="../../../../help-doc.html">Help</a></li>
|
|
</ul>
|
|
</div>
|
|
<div class="subNav">
|
|
<ul class="navList">
|
|
<li>Prev Package</li>
|
|
<li><a href="../../../../org/apache/commons/io/comparator/package-summary.html">Next Package</a></li>
|
|
</ul>
|
|
<ul class="navList">
|
|
<li><a href="../../../../index.html?org/apache/commons/io/package-summary.html" target="_top">Frames</a></li>
|
|
<li><a href="package-summary.html" target="_top">No Frames</a></li>
|
|
</ul>
|
|
<ul class="navList" id="allclasses_navbar_bottom">
|
|
<li><a href="../../../../allclasses-noframe.html">All Classes</a></li>
|
|
</ul>
|
|
<div>
|
|
<script type="text/javascript"><!--
|
|
allClassesLink = document.getElementById("allclasses_navbar_bottom");
|
|
if(window==top) {
|
|
allClassesLink.style.display = "block";
|
|
}
|
|
else {
|
|
allClassesLink.style.display = "none";
|
|
}
|
|
//-->
|
|
</script>
|
|
</div>
|
|
<a name="skip.navbar.bottom">
|
|
<!-- -->
|
|
</a></div>
|
|
<!-- ======== END OF BOTTOM NAVBAR ======= -->
|
|
<p class="legalCopy"><small>Copyright © 2002–2021 <a href="https://www.apache.org/">The Apache Software Foundation</a>. All rights reserved.</small></p>
|
|
</body>
|
|
</html>
|