????

Your IP : 216.73.216.152


Current Path : /opt/ant/manual/api/org/apache/tools/tar/
Upload File :
Current File : //opt/ant/manual/api/org/apache/tools/tar/TarEntry.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 (version 1.7.0_03) on Tue May 22 06:24:55 CEST 2012 -->
<title>TarEntry (Apache Ant API)</title>
<meta name="date" content="2012-05-22">
<link rel="stylesheet" type="text/css" href="../../../../stylesheet.css" title="Style">
</head>
<body>
<script type="text/javascript"><!--
    if (location.href.indexOf('is-external=true') == -1) {
        parent.document.title="TarEntry (Apache Ant API)";
    }
//-->
</script>
<noscript>
<div>JavaScript is disabled on your browser.</div>
</noscript>
<!-- ========= START OF TOP NAVBAR ======= -->
<div class="topNav"><a name="navbar_top">
<!--   -->
</a><a href="#skip-navbar_top" title="Skip navigation links"></a><a name="navbar_top_firstrow">
<!--   -->
</a>
<ul class="navList" title="Navigation">
<li><a href="../../../../overview-summary.html">Overview</a></li>
<li><a href="package-summary.html">Package</a></li>
<li class="navBarCell1Rev">Class</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><a href="../../../../org/apache/tools/tar/TarConstants.html" title="interface in org.apache.tools.tar"><span class="strong">Prev Class</span></a></li>
<li><a href="../../../../org/apache/tools/tar/TarInputStream.html" title="class in org.apache.tools.tar"><span class="strong">Next Class</span></a></li>
</ul>
<ul class="navList">
<li><a href="../../../../index.html?org/apache/tools/tar/TarEntry.html" target="_top">Frames</a></li>
<li><a href="TarEntry.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>
<div>
<ul class="subNavList">
<li>Summary:&nbsp;</li>
<li>Nested&nbsp;|&nbsp;</li>
<li><a href="#field_summary">Field</a>&nbsp;|&nbsp;</li>
<li><a href="#constructor_summary">Constr</a>&nbsp;|&nbsp;</li>
<li><a href="#method_summary">Method</a></li>
</ul>
<ul class="subNavList">
<li>Detail:&nbsp;</li>
<li><a href="#field_detail">Field</a>&nbsp;|&nbsp;</li>
<li><a href="#constructor_detail">Constr</a>&nbsp;|&nbsp;</li>
<li><a href="#method_detail">Method</a></li>
</ul>
</div>
<a name="skip-navbar_top">
<!--   -->
</a></div>
<!-- ========= END OF TOP NAVBAR ========= -->
<!-- ======== START OF CLASS DATA ======== -->
<div class="header">
<div class="subTitle">org.apache.tools.tar</div>
<h2 title="Class TarEntry" class="title">Class TarEntry</h2>
</div>
<div class="contentContainer">
<ul class="inheritance">
<li>java.lang.Object</li>
<li>
<ul class="inheritance">
<li>org.apache.tools.tar.TarEntry</li>
</ul>
</li>
</ul>
<div class="description">
<ul class="blockList">
<li class="blockList">
<dl>
<dt>All Implemented Interfaces:</dt>
<dd><a href="../../../../org/apache/tools/tar/TarConstants.html" title="interface in org.apache.tools.tar">TarConstants</a></dd>
</dl>
<hr>
<br>
<pre>public class <span class="strong">TarEntry</span>
extends java.lang.Object
implements <a href="../../../../org/apache/tools/tar/TarConstants.html" title="interface in org.apache.tools.tar">TarConstants</a></pre>
<div class="block">This class represents an entry in a Tar archive. It consists
 of the entry's header, as well as the entry's File. Entries
 can be instantiated in one of three ways, depending on how
 they are to be used.
 <p>
 TarEntries that are created from the header bytes read from
 an archive are instantiated with the TarEntry( byte[] )
 constructor. These entries will be used when extracting from
 or listing the contents of an archive. These entries have their
 header filled in using the header bytes. They also set the File
 to null, since they reference an archive entry not a file.
 <p>
 TarEntries that are created from Files that are to be written
 into an archive are instantiated with the TarEntry( File )
 constructor. These entries have their header filled in using
 the File's information. They also keep a reference to the File
 for convenience when writing entries.
 <p>
 Finally, TarEntries can be constructed from nothing but a name.
 This allows the programmer to construct the entry by hand, for
 instance when only an InputStream is available for writing to
 the archive, and the header information is constructed from
 other information. In this case the header fields are set to
 defaults and the File is set to null.

 <p>
 The C structure for a Tar Entry's header is:
 <pre>
 struct header {
 char name[NAMSIZ];
 char mode[8];
 char uid[8];
 char gid[8];
 char size[12];
 char mtime[12];
 char chksum[8];
 char linkflag;
 char linkname[NAMSIZ];
 char magic[8];
 char uname[TUNMLEN];
 char gname[TGNMLEN];
 char devmajor[8];
 char devminor[8];
 } header;
 </pre></div>
</li>
</ul>
</div>
<div class="summary">
<ul class="blockList">
<li class="blockList">
<!-- =========== FIELD SUMMARY =========== -->
<ul class="blockList">
<li class="blockList"><a name="field_summary">
<!--   -->
</a>
<h3>Field Summary</h3>
<table class="overviewSummary" border="0" cellpadding="3" cellspacing="0" summary="Field Summary table, listing fields, and an explanation">
<caption><span>Fields</span><span class="tabEnd">&nbsp;</span></caption>
<tr>
<th class="colFirst" scope="col">Modifier and Type</th>
<th class="colLast" scope="col">Field and Description</th>
</tr>
<tr class="altColor">
<td class="colFirst"><code>static int</code></td>
<td class="colLast"><code><strong><a href="../../../../org/apache/tools/tar/TarEntry.html#DEFAULT_DIR_MODE">DEFAULT_DIR_MODE</a></strong></code>
<div class="block">Default permissions bits for directories</div>
</td>
</tr>
<tr class="rowColor">
<td class="colFirst"><code>static int</code></td>
<td class="colLast"><code><strong><a href="../../../../org/apache/tools/tar/TarEntry.html#DEFAULT_FILE_MODE">DEFAULT_FILE_MODE</a></strong></code>
<div class="block">Default permissions bits for files</div>
</td>
</tr>
<tr class="altColor">
<td class="colFirst"><code>static int</code></td>
<td class="colLast"><code><strong><a href="../../../../org/apache/tools/tar/TarEntry.html#MAX_NAMELEN">MAX_NAMELEN</a></strong></code>
<div class="block">Maximum length of a user's name in the tar file</div>
</td>
</tr>
<tr class="rowColor">
<td class="colFirst"><code>static int</code></td>
<td class="colLast"><code><strong><a href="../../../../org/apache/tools/tar/TarEntry.html#MILLIS_PER_SECOND">MILLIS_PER_SECOND</a></strong></code>
<div class="block">Convert millis to seconds</div>
</td>
</tr>
</table>
<ul class="blockList">
<li class="blockList"><a name="fields_inherited_from_class_org.apache.tools.tar.TarConstants">
<!--   -->
</a>
<h3>Fields inherited from interface&nbsp;org.apache.tools.tar.<a href="../../../../org/apache/tools/tar/TarConstants.html" title="interface in org.apache.tools.tar">TarConstants</a></h3>
<code><a href="../../../../org/apache/tools/tar/TarConstants.html#CHKSUMLEN">CHKSUMLEN</a>, <a href="../../../../org/apache/tools/tar/TarConstants.html#DEVLEN">DEVLEN</a>, <a href="../../../../org/apache/tools/tar/TarConstants.html#GIDLEN">GIDLEN</a>, <a href="../../../../org/apache/tools/tar/TarConstants.html#GNAMELEN">GNAMELEN</a>, <a href="../../../../org/apache/tools/tar/TarConstants.html#GNU_LONGLINK">GNU_LONGLINK</a>, <a href="../../../../org/apache/tools/tar/TarConstants.html#GNU_TMAGIC">GNU_TMAGIC</a>, <a href="../../../../org/apache/tools/tar/TarConstants.html#LF_BLK">LF_BLK</a>, <a href="../../../../org/apache/tools/tar/TarConstants.html#LF_CHR">LF_CHR</a>, <a href="../../../../org/apache/tools/tar/TarConstants.html#LF_CONTIG">LF_CONTIG</a>, <a href="../../../../org/apache/tools/tar/TarConstants.html#LF_DIR">LF_DIR</a>, <a href="../../../../org/apache/tools/tar/TarConstants.html#LF_FIFO">LF_FIFO</a>, <a href="../../../../org/apache/tools/tar/TarConstants.html#LF_GNUTYPE_LONGNAME">LF_GNUTYPE_LONGNAME</a>, <a href="../../../../org/apache/tools/tar/TarConstants.html#LF_LINK">LF_LINK</a>, <a href="../../../../org/apache/tools/tar/TarConstants.html#LF_NORMAL">LF_NORMAL</a>, <a href="../../../../org/apache/tools/tar/TarConstants.html#LF_OLDNORM">LF_OLDNORM</a>, <a href="../../../../org/apache/tools/tar/TarConstants.html#LF_SYMLINK">LF_SYMLINK</a>, <a href="../../../../org/apache/tools/tar/TarConstants.html#MAGICLEN">MAGICLEN</a>, <a href="../../../../org/apache/tools/tar/TarConstants.html#MAXSIZE">MAXSIZE</a>, <a href="../../../../org/apache/tools/tar/TarConstants.html#MODELEN">MODELEN</a>, <a href="../../../../org/apache/tools/tar/TarConstants.html#MODTIMELEN">MODTIMELEN</a>, <a href="../../../../org/apache/tools/tar/TarConstants.html#NAMELEN">NAMELEN</a>, <a href="../../../../org/apache/tools/tar/TarConstants.html#SIZELEN">SIZELEN</a>, <a href="../../../../org/apache/tools/tar/TarConstants.html#TMAGIC">TMAGIC</a>, <a href="../../../../org/apache/tools/tar/TarConstants.html#UIDLEN">UIDLEN</a>, <a href="../../../../org/apache/tools/tar/TarConstants.html#UNAMELEN">UNAMELEN</a></code></li>
</ul>
</li>
</ul>
<!-- ======== CONSTRUCTOR SUMMARY ======== -->
<ul class="blockList">
<li class="blockList"><a name="constructor_summary">
<!--   -->
</a>
<h3>Constructor Summary</h3>
<table class="overviewSummary" border="0" cellpadding="3" cellspacing="0" summary="Constructor Summary table, listing constructors, and an explanation">
<caption><span>Constructors</span><span class="tabEnd">&nbsp;</span></caption>
<tr>
<th class="colOne" scope="col">Constructor and Description</th>
</tr>
<tr class="altColor">
<td class="colOne"><code><strong><a href="../../../../org/apache/tools/tar/TarEntry.html#TarEntry(byte[])">TarEntry</a></strong>(byte[]&nbsp;headerBuf)</code>
<div class="block">Construct an entry from an archive's header bytes.</div>
</td>
</tr>
<tr class="rowColor">
<td class="colOne"><code><strong><a href="../../../../org/apache/tools/tar/TarEntry.html#TarEntry(java.io.File)">TarEntry</a></strong>(java.io.File&nbsp;file)</code>
<div class="block">Construct an entry for a file.</div>
</td>
</tr>
<tr class="altColor">
<td class="colOne"><code><strong><a href="../../../../org/apache/tools/tar/TarEntry.html#TarEntry(java.lang.String)">TarEntry</a></strong>(java.lang.String&nbsp;name)</code>
<div class="block">Construct an entry with only a name.</div>
</td>
</tr>
<tr class="rowColor">
<td class="colOne"><code><strong><a href="../../../../org/apache/tools/tar/TarEntry.html#TarEntry(java.lang.String, boolean)">TarEntry</a></strong>(java.lang.String&nbsp;name,
        boolean&nbsp;preserveLeadingSlashes)</code>
<div class="block">Construct an entry with only a name.</div>
</td>
</tr>
<tr class="altColor">
<td class="colOne"><code><strong><a href="../../../../org/apache/tools/tar/TarEntry.html#TarEntry(java.lang.String, byte)">TarEntry</a></strong>(java.lang.String&nbsp;name,
        byte&nbsp;linkFlag)</code>
<div class="block">Construct an entry with a name and a link flag.</div>
</td>
</tr>
</table>
</li>
</ul>
<!-- ========== METHOD SUMMARY =========== -->
<ul class="blockList">
<li class="blockList"><a name="method_summary">
<!--   -->
</a>
<h3>Method Summary</h3>
<table class="overviewSummary" border="0" cellpadding="3" cellspacing="0" summary="Method Summary table, listing methods, and an explanation">
<caption><span>Methods</span><span class="tabEnd">&nbsp;</span></caption>
<tr>
<th class="colFirst" scope="col">Modifier and Type</th>
<th class="colLast" scope="col">Method and Description</th>
</tr>
<tr class="altColor">
<td class="colFirst"><code>boolean</code></td>
<td class="colLast"><code><strong><a href="../../../../org/apache/tools/tar/TarEntry.html#equals(java.lang.Object)">equals</a></strong>(java.lang.Object&nbsp;it)</code>
<div class="block">Determine if the two entries are equal.</div>
</td>
</tr>
<tr class="rowColor">
<td class="colFirst"><code>boolean</code></td>
<td class="colLast"><code><strong><a href="../../../../org/apache/tools/tar/TarEntry.html#equals(org.apache.tools.tar.TarEntry)">equals</a></strong>(<a href="../../../../org/apache/tools/tar/TarEntry.html" title="class in org.apache.tools.tar">TarEntry</a>&nbsp;it)</code>
<div class="block">Determine if the two entries are equal.</div>
</td>
</tr>
<tr class="altColor">
<td class="colFirst"><code><a href="../../../../org/apache/tools/tar/TarEntry.html" title="class in org.apache.tools.tar">TarEntry</a>[]</code></td>
<td class="colLast"><code><strong><a href="../../../../org/apache/tools/tar/TarEntry.html#getDirectoryEntries()">getDirectoryEntries</a></strong>()</code>
<div class="block">If this entry represents a file, and the file is a directory, return
 an array of TarEntries for this entry's children.</div>
</td>
</tr>
<tr class="rowColor">
<td class="colFirst"><code>java.io.File</code></td>
<td class="colLast"><code><strong><a href="../../../../org/apache/tools/tar/TarEntry.html#getFile()">getFile</a></strong>()</code>
<div class="block">Get this entry's file.</div>
</td>
</tr>
<tr class="altColor">
<td class="colFirst"><code>int</code></td>
<td class="colLast"><code><strong><a href="../../../../org/apache/tools/tar/TarEntry.html#getGroupId()">getGroupId</a></strong>()</code>
<div class="block">Get this entry's group id.</div>
</td>
</tr>
<tr class="rowColor">
<td class="colFirst"><code>java.lang.String</code></td>
<td class="colLast"><code><strong><a href="../../../../org/apache/tools/tar/TarEntry.html#getGroupName()">getGroupName</a></strong>()</code>
<div class="block">Get this entry's group name.</div>
</td>
</tr>
<tr class="altColor">
<td class="colFirst"><code>java.lang.String</code></td>
<td class="colLast"><code><strong><a href="../../../../org/apache/tools/tar/TarEntry.html#getLinkName()">getLinkName</a></strong>()</code>
<div class="block">Get this entry's link name.</div>
</td>
</tr>
<tr class="rowColor">
<td class="colFirst"><code>int</code></td>
<td class="colLast"><code><strong><a href="../../../../org/apache/tools/tar/TarEntry.html#getMode()">getMode</a></strong>()</code>
<div class="block">Get this entry's mode.</div>
</td>
</tr>
<tr class="altColor">
<td class="colFirst"><code>java.util.Date</code></td>
<td class="colLast"><code><strong><a href="../../../../org/apache/tools/tar/TarEntry.html#getModTime()">getModTime</a></strong>()</code>
<div class="block">Set this entry's modification time.</div>
</td>
</tr>
<tr class="rowColor">
<td class="colFirst"><code>java.lang.String</code></td>
<td class="colLast"><code><strong><a href="../../../../org/apache/tools/tar/TarEntry.html#getName()">getName</a></strong>()</code>
<div class="block">Get this entry's name.</div>
</td>
</tr>
<tr class="altColor">
<td class="colFirst"><code>long</code></td>
<td class="colLast"><code><strong><a href="../../../../org/apache/tools/tar/TarEntry.html#getSize()">getSize</a></strong>()</code>
<div class="block">Get this entry's file size.</div>
</td>
</tr>
<tr class="rowColor">
<td class="colFirst"><code>int</code></td>
<td class="colLast"><code><strong><a href="../../../../org/apache/tools/tar/TarEntry.html#getUserId()">getUserId</a></strong>()</code>
<div class="block">Get this entry's user id.</div>
</td>
</tr>
<tr class="altColor">
<td class="colFirst"><code>java.lang.String</code></td>
<td class="colLast"><code><strong><a href="../../../../org/apache/tools/tar/TarEntry.html#getUserName()">getUserName</a></strong>()</code>
<div class="block">Get this entry's user name.</div>
</td>
</tr>
<tr class="rowColor">
<td class="colFirst"><code>int</code></td>
<td class="colLast"><code><strong><a href="../../../../org/apache/tools/tar/TarEntry.html#hashCode()">hashCode</a></strong>()</code>
<div class="block">Hashcodes are based on entry names.</div>
</td>
</tr>
<tr class="altColor">
<td class="colFirst"><code>boolean</code></td>
<td class="colLast"><code><strong><a href="../../../../org/apache/tools/tar/TarEntry.html#isDescendent(org.apache.tools.tar.TarEntry)">isDescendent</a></strong>(<a href="../../../../org/apache/tools/tar/TarEntry.html" title="class in org.apache.tools.tar">TarEntry</a>&nbsp;desc)</code>
<div class="block">Determine if the given entry is a descendant of this entry.</div>
</td>
</tr>
<tr class="rowColor">
<td class="colFirst"><code>boolean</code></td>
<td class="colLast"><code><strong><a href="../../../../org/apache/tools/tar/TarEntry.html#isDirectory()">isDirectory</a></strong>()</code>
<div class="block">Return whether or not this entry represents a directory.</div>
</td>
</tr>
<tr class="altColor">
<td class="colFirst"><code>boolean</code></td>
<td class="colLast"><code><strong><a href="../../../../org/apache/tools/tar/TarEntry.html#isGNULongNameEntry()">isGNULongNameEntry</a></strong>()</code>
<div class="block">Indicate if this entry is a GNU long name block</div>
</td>
</tr>
<tr class="rowColor">
<td class="colFirst"><code>void</code></td>
<td class="colLast"><code><strong><a href="../../../../org/apache/tools/tar/TarEntry.html#parseTarHeader(byte[])">parseTarHeader</a></strong>(byte[]&nbsp;header)</code>
<div class="block">Parse an entry's header information from a header buffer.</div>
</td>
</tr>
<tr class="altColor">
<td class="colFirst"><code>void</code></td>
<td class="colLast"><code><strong><a href="../../../../org/apache/tools/tar/TarEntry.html#setGroupId(int)">setGroupId</a></strong>(int&nbsp;groupId)</code>
<div class="block">Set this entry's group id.</div>
</td>
</tr>
<tr class="rowColor">
<td class="colFirst"><code>void</code></td>
<td class="colLast"><code><strong><a href="../../../../org/apache/tools/tar/TarEntry.html#setGroupName(java.lang.String)">setGroupName</a></strong>(java.lang.String&nbsp;groupName)</code>
<div class="block">Set this entry's group name.</div>
</td>
</tr>
<tr class="altColor">
<td class="colFirst"><code>void</code></td>
<td class="colLast"><code><strong><a href="../../../../org/apache/tools/tar/TarEntry.html#setIds(int, int)">setIds</a></strong>(int&nbsp;userId,
      int&nbsp;groupId)</code>
<div class="block">Convenience method to set this entry's group and user ids.</div>
</td>
</tr>
<tr class="rowColor">
<td class="colFirst"><code>void</code></td>
<td class="colLast"><code><strong><a href="../../../../org/apache/tools/tar/TarEntry.html#setMode(int)">setMode</a></strong>(int&nbsp;mode)</code>
<div class="block">Set the mode for this entry</div>
</td>
</tr>
<tr class="altColor">
<td class="colFirst"><code>void</code></td>
<td class="colLast"><code><strong><a href="../../../../org/apache/tools/tar/TarEntry.html#setModTime(java.util.Date)">setModTime</a></strong>(java.util.Date&nbsp;time)</code>
<div class="block">Set this entry's modification time.</div>
</td>
</tr>
<tr class="rowColor">
<td class="colFirst"><code>void</code></td>
<td class="colLast"><code><strong><a href="../../../../org/apache/tools/tar/TarEntry.html#setModTime(long)">setModTime</a></strong>(long&nbsp;time)</code>
<div class="block">Set this entry's modification time.</div>
</td>
</tr>
<tr class="altColor">
<td class="colFirst"><code>void</code></td>
<td class="colLast"><code><strong><a href="../../../../org/apache/tools/tar/TarEntry.html#setName(java.lang.String)">setName</a></strong>(java.lang.String&nbsp;name)</code>
<div class="block">Set this entry's name.</div>
</td>
</tr>
<tr class="rowColor">
<td class="colFirst"><code>void</code></td>
<td class="colLast"><code><strong><a href="../../../../org/apache/tools/tar/TarEntry.html#setNames(java.lang.String, java.lang.String)">setNames</a></strong>(java.lang.String&nbsp;userName,
        java.lang.String&nbsp;groupName)</code>
<div class="block">Convenience method to set this entry's group and user names.</div>
</td>
</tr>
<tr class="altColor">
<td class="colFirst"><code>void</code></td>
<td class="colLast"><code><strong><a href="../../../../org/apache/tools/tar/TarEntry.html#setSize(long)">setSize</a></strong>(long&nbsp;size)</code>
<div class="block">Set this entry's file size.</div>
</td>
</tr>
<tr class="rowColor">
<td class="colFirst"><code>void</code></td>
<td class="colLast"><code><strong><a href="../../../../org/apache/tools/tar/TarEntry.html#setUserId(int)">setUserId</a></strong>(int&nbsp;userId)</code>
<div class="block">Set this entry's user id.</div>
</td>
</tr>
<tr class="altColor">
<td class="colFirst"><code>void</code></td>
<td class="colLast"><code><strong><a href="../../../../org/apache/tools/tar/TarEntry.html#setUserName(java.lang.String)">setUserName</a></strong>(java.lang.String&nbsp;userName)</code>
<div class="block">Set this entry's user name.</div>
</td>
</tr>
<tr class="rowColor">
<td class="colFirst"><code>void</code></td>
<td class="colLast"><code><strong><a href="../../../../org/apache/tools/tar/TarEntry.html#writeEntryHeader(byte[])">writeEntryHeader</a></strong>(byte[]&nbsp;outbuf)</code>
<div class="block">Write an entry's header information to a header buffer.</div>
</td>
</tr>
</table>
<ul class="blockList">
<li class="blockList"><a name="methods_inherited_from_class_java.lang.Object">
<!--   -->
</a>
<h3>Methods inherited from class&nbsp;java.lang.Object</h3>
<code>clone, finalize, getClass, notify, notifyAll, toString, wait, wait, wait</code></li>
</ul>
</li>
</ul>
</li>
</ul>
</div>
<div class="details">
<ul class="blockList">
<li class="blockList">
<!-- ============ FIELD DETAIL =========== -->
<ul class="blockList">
<li class="blockList"><a name="field_detail">
<!--   -->
</a>
<h3>Field Detail</h3>
<a name="MAX_NAMELEN">
<!--   -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>MAX_NAMELEN</h4>
<pre>public static final&nbsp;int MAX_NAMELEN</pre>
<div class="block">Maximum length of a user's name in the tar file</div>
<dl><dt><span class="strong">See Also:</span></dt><dd><a href="../../../../constant-values.html#org.apache.tools.tar.TarEntry.MAX_NAMELEN">Constant Field Values</a></dd></dl>
</li>
</ul>
<a name="DEFAULT_DIR_MODE">
<!--   -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>DEFAULT_DIR_MODE</h4>
<pre>public static final&nbsp;int DEFAULT_DIR_MODE</pre>
<div class="block">Default permissions bits for directories</div>
<dl><dt><span class="strong">See Also:</span></dt><dd><a href="../../../../constant-values.html#org.apache.tools.tar.TarEntry.DEFAULT_DIR_MODE">Constant Field Values</a></dd></dl>
</li>
</ul>
<a name="DEFAULT_FILE_MODE">
<!--   -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>DEFAULT_FILE_MODE</h4>
<pre>public static final&nbsp;int DEFAULT_FILE_MODE</pre>
<div class="block">Default permissions bits for files</div>
<dl><dt><span class="strong">See Also:</span></dt><dd><a href="../../../../constant-values.html#org.apache.tools.tar.TarEntry.DEFAULT_FILE_MODE">Constant Field Values</a></dd></dl>
</li>
</ul>
<a name="MILLIS_PER_SECOND">
<!--   -->
</a>
<ul class="blockListLast">
<li class="blockList">
<h4>MILLIS_PER_SECOND</h4>
<pre>public static final&nbsp;int MILLIS_PER_SECOND</pre>
<div class="block">Convert millis to seconds</div>
<dl><dt><span class="strong">See Also:</span></dt><dd><a href="../../../../constant-values.html#org.apache.tools.tar.TarEntry.MILLIS_PER_SECOND">Constant Field Values</a></dd></dl>
</li>
</ul>
</li>
</ul>
<!-- ========= CONSTRUCTOR DETAIL ======== -->
<ul class="blockList">
<li class="blockList"><a name="constructor_detail">
<!--   -->
</a>
<h3>Constructor Detail</h3>
<a name="TarEntry(java.lang.String)">
<!--   -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>TarEntry</h4>
<pre>public&nbsp;TarEntry(java.lang.String&nbsp;name)</pre>
<div class="block">Construct an entry with only a name. This allows the programmer
 to construct the entry's header "by hand". File is set to null.</div>
<dl><dt><span class="strong">Parameters:</span></dt><dd><code>name</code> - the entry name</dd></dl>
</li>
</ul>
<a name="TarEntry(java.lang.String, boolean)">
<!--   -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>TarEntry</h4>
<pre>public&nbsp;TarEntry(java.lang.String&nbsp;name,
        boolean&nbsp;preserveLeadingSlashes)</pre>
<div class="block">Construct an entry with only a name. This allows the programmer
 to construct the entry's header "by hand". File is set to null.</div>
<dl><dt><span class="strong">Parameters:</span></dt><dd><code>name</code> - the entry name</dd><dd><code>preserveLeadingSlashes</code> - whether to allow leading slashes
 in the name.</dd></dl>
</li>
</ul>
<a name="TarEntry(java.lang.String, byte)">
<!--   -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>TarEntry</h4>
<pre>public&nbsp;TarEntry(java.lang.String&nbsp;name,
        byte&nbsp;linkFlag)</pre>
<div class="block">Construct an entry with a name and a link flag.</div>
<dl><dt><span class="strong">Parameters:</span></dt><dd><code>name</code> - the entry name</dd><dd><code>linkFlag</code> - the entry link flag.</dd></dl>
</li>
</ul>
<a name="TarEntry(java.io.File)">
<!--   -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>TarEntry</h4>
<pre>public&nbsp;TarEntry(java.io.File&nbsp;file)</pre>
<div class="block">Construct an entry for a file. File is set to file, and the
 header is constructed from information from the file.</div>
<dl><dt><span class="strong">Parameters:</span></dt><dd><code>file</code> - The file that the entry represents.</dd></dl>
</li>
</ul>
<a name="TarEntry(byte[])">
<!--   -->
</a>
<ul class="blockListLast">
<li class="blockList">
<h4>TarEntry</h4>
<pre>public&nbsp;TarEntry(byte[]&nbsp;headerBuf)</pre>
<div class="block">Construct an entry from an archive's header bytes. File is set
 to null.</div>
<dl><dt><span class="strong">Parameters:</span></dt><dd><code>headerBuf</code> - The header bytes from a tar archive entry.</dd></dl>
</li>
</ul>
</li>
</ul>
<!-- ============ METHOD DETAIL ========== -->
<ul class="blockList">
<li class="blockList"><a name="method_detail">
<!--   -->
</a>
<h3>Method Detail</h3>
<a name="equals(org.apache.tools.tar.TarEntry)">
<!--   -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>equals</h4>
<pre>public&nbsp;boolean&nbsp;equals(<a href="../../../../org/apache/tools/tar/TarEntry.html" title="class in org.apache.tools.tar">TarEntry</a>&nbsp;it)</pre>
<div class="block">Determine if the two entries are equal. Equality is determined
 by the header names being equal.</div>
<dl><dt><span class="strong">Parameters:</span></dt><dd><code>it</code> - Entry to be checked for equality.</dd>
<dt><span class="strong">Returns:</span></dt><dd>True if the entries are equal.</dd></dl>
</li>
</ul>
<a name="equals(java.lang.Object)">
<!--   -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>equals</h4>
<pre>public&nbsp;boolean&nbsp;equals(java.lang.Object&nbsp;it)</pre>
<div class="block">Determine if the two entries are equal. Equality is determined
 by the header names being equal.</div>
<dl>
<dt><strong>Overrides:</strong></dt>
<dd><code>equals</code>&nbsp;in class&nbsp;<code>java.lang.Object</code></dd>
<dt><span class="strong">Parameters:</span></dt><dd><code>it</code> - Entry to be checked for equality.</dd>
<dt><span class="strong">Returns:</span></dt><dd>True if the entries are equal.</dd></dl>
</li>
</ul>
<a name="hashCode()">
<!--   -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>hashCode</h4>
<pre>public&nbsp;int&nbsp;hashCode()</pre>
<div class="block">Hashcodes are based on entry names.</div>
<dl>
<dt><strong>Overrides:</strong></dt>
<dd><code>hashCode</code>&nbsp;in class&nbsp;<code>java.lang.Object</code></dd>
<dt><span class="strong">Returns:</span></dt><dd>the entry hashcode</dd></dl>
</li>
</ul>
<a name="isDescendent(org.apache.tools.tar.TarEntry)">
<!--   -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>isDescendent</h4>
<pre>public&nbsp;boolean&nbsp;isDescendent(<a href="../../../../org/apache/tools/tar/TarEntry.html" title="class in org.apache.tools.tar">TarEntry</a>&nbsp;desc)</pre>
<div class="block">Determine if the given entry is a descendant of this entry.
 Descendancy is determined by the name of the descendant
 starting with this entry's name.</div>
<dl><dt><span class="strong">Parameters:</span></dt><dd><code>desc</code> - Entry to be checked as a descendent of this.</dd>
<dt><span class="strong">Returns:</span></dt><dd>True if entry is a descendant of this.</dd></dl>
</li>
</ul>
<a name="getName()">
<!--   -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>getName</h4>
<pre>public&nbsp;java.lang.String&nbsp;getName()</pre>
<div class="block">Get this entry's name.</div>
<dl><dt><span class="strong">Returns:</span></dt><dd>This entry's name.</dd></dl>
</li>
</ul>
<a name="setName(java.lang.String)">
<!--   -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>setName</h4>
<pre>public&nbsp;void&nbsp;setName(java.lang.String&nbsp;name)</pre>
<div class="block">Set this entry's name.</div>
<dl><dt><span class="strong">Parameters:</span></dt><dd><code>name</code> - This entry's new name.</dd></dl>
</li>
</ul>
<a name="setMode(int)">
<!--   -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>setMode</h4>
<pre>public&nbsp;void&nbsp;setMode(int&nbsp;mode)</pre>
<div class="block">Set the mode for this entry</div>
<dl><dt><span class="strong">Parameters:</span></dt><dd><code>mode</code> - the mode for this entry</dd></dl>
</li>
</ul>
<a name="getLinkName()">
<!--   -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>getLinkName</h4>
<pre>public&nbsp;java.lang.String&nbsp;getLinkName()</pre>
<div class="block">Get this entry's link name.</div>
<dl><dt><span class="strong">Returns:</span></dt><dd>This entry's link name.</dd></dl>
</li>
</ul>
<a name="getUserId()">
<!--   -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>getUserId</h4>
<pre>public&nbsp;int&nbsp;getUserId()</pre>
<div class="block">Get this entry's user id.</div>
<dl><dt><span class="strong">Returns:</span></dt><dd>This entry's user id.</dd></dl>
</li>
</ul>
<a name="setUserId(int)">
<!--   -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>setUserId</h4>
<pre>public&nbsp;void&nbsp;setUserId(int&nbsp;userId)</pre>
<div class="block">Set this entry's user id.</div>
<dl><dt><span class="strong">Parameters:</span></dt><dd><code>userId</code> - This entry's new user id.</dd></dl>
</li>
</ul>
<a name="getGroupId()">
<!--   -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>getGroupId</h4>
<pre>public&nbsp;int&nbsp;getGroupId()</pre>
<div class="block">Get this entry's group id.</div>
<dl><dt><span class="strong">Returns:</span></dt><dd>This entry's group id.</dd></dl>
</li>
</ul>
<a name="setGroupId(int)">
<!--   -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>setGroupId</h4>
<pre>public&nbsp;void&nbsp;setGroupId(int&nbsp;groupId)</pre>
<div class="block">Set this entry's group id.</div>
<dl><dt><span class="strong">Parameters:</span></dt><dd><code>groupId</code> - This entry's new group id.</dd></dl>
</li>
</ul>
<a name="getUserName()">
<!--   -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>getUserName</h4>
<pre>public&nbsp;java.lang.String&nbsp;getUserName()</pre>
<div class="block">Get this entry's user name.</div>
<dl><dt><span class="strong">Returns:</span></dt><dd>This entry's user name.</dd></dl>
</li>
</ul>
<a name="setUserName(java.lang.String)">
<!--   -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>setUserName</h4>
<pre>public&nbsp;void&nbsp;setUserName(java.lang.String&nbsp;userName)</pre>
<div class="block">Set this entry's user name.</div>
<dl><dt><span class="strong">Parameters:</span></dt><dd><code>userName</code> - This entry's new user name.</dd></dl>
</li>
</ul>
<a name="getGroupName()">
<!--   -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>getGroupName</h4>
<pre>public&nbsp;java.lang.String&nbsp;getGroupName()</pre>
<div class="block">Get this entry's group name.</div>
<dl><dt><span class="strong">Returns:</span></dt><dd>This entry's group name.</dd></dl>
</li>
</ul>
<a name="setGroupName(java.lang.String)">
<!--   -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>setGroupName</h4>
<pre>public&nbsp;void&nbsp;setGroupName(java.lang.String&nbsp;groupName)</pre>
<div class="block">Set this entry's group name.</div>
<dl><dt><span class="strong">Parameters:</span></dt><dd><code>groupName</code> - This entry's new group name.</dd></dl>
</li>
</ul>
<a name="setIds(int, int)">
<!--   -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>setIds</h4>
<pre>public&nbsp;void&nbsp;setIds(int&nbsp;userId,
          int&nbsp;groupId)</pre>
<div class="block">Convenience method to set this entry's group and user ids.</div>
<dl><dt><span class="strong">Parameters:</span></dt><dd><code>userId</code> - This entry's new user id.</dd><dd><code>groupId</code> - This entry's new group id.</dd></dl>
</li>
</ul>
<a name="setNames(java.lang.String, java.lang.String)">
<!--   -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>setNames</h4>
<pre>public&nbsp;void&nbsp;setNames(java.lang.String&nbsp;userName,
            java.lang.String&nbsp;groupName)</pre>
<div class="block">Convenience method to set this entry's group and user names.</div>
<dl><dt><span class="strong">Parameters:</span></dt><dd><code>userName</code> - This entry's new user name.</dd><dd><code>groupName</code> - This entry's new group name.</dd></dl>
</li>
</ul>
<a name="setModTime(long)">
<!--   -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>setModTime</h4>
<pre>public&nbsp;void&nbsp;setModTime(long&nbsp;time)</pre>
<div class="block">Set this entry's modification time. The parameter passed
 to this method is in "Java time".</div>
<dl><dt><span class="strong">Parameters:</span></dt><dd><code>time</code> - This entry's new modification time.</dd></dl>
</li>
</ul>
<a name="setModTime(java.util.Date)">
<!--   -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>setModTime</h4>
<pre>public&nbsp;void&nbsp;setModTime(java.util.Date&nbsp;time)</pre>
<div class="block">Set this entry's modification time.</div>
<dl><dt><span class="strong">Parameters:</span></dt><dd><code>time</code> - This entry's new modification time.</dd></dl>
</li>
</ul>
<a name="getModTime()">
<!--   -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>getModTime</h4>
<pre>public&nbsp;java.util.Date&nbsp;getModTime()</pre>
<div class="block">Set this entry's modification time.</div>
<dl><dt><span class="strong">Returns:</span></dt><dd>time This entry's new modification time.</dd></dl>
</li>
</ul>
<a name="getFile()">
<!--   -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>getFile</h4>
<pre>public&nbsp;java.io.File&nbsp;getFile()</pre>
<div class="block">Get this entry's file.</div>
<dl><dt><span class="strong">Returns:</span></dt><dd>This entry's file.</dd></dl>
</li>
</ul>
<a name="getMode()">
<!--   -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>getMode</h4>
<pre>public&nbsp;int&nbsp;getMode()</pre>
<div class="block">Get this entry's mode.</div>
<dl><dt><span class="strong">Returns:</span></dt><dd>This entry's mode.</dd></dl>
</li>
</ul>
<a name="getSize()">
<!--   -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>getSize</h4>
<pre>public&nbsp;long&nbsp;getSize()</pre>
<div class="block">Get this entry's file size.</div>
<dl><dt><span class="strong">Returns:</span></dt><dd>This entry's file size.</dd></dl>
</li>
</ul>
<a name="setSize(long)">
<!--   -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>setSize</h4>
<pre>public&nbsp;void&nbsp;setSize(long&nbsp;size)</pre>
<div class="block">Set this entry's file size.</div>
<dl><dt><span class="strong">Parameters:</span></dt><dd><code>size</code> - This entry's new file size.</dd></dl>
</li>
</ul>
<a name="isGNULongNameEntry()">
<!--   -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>isGNULongNameEntry</h4>
<pre>public&nbsp;boolean&nbsp;isGNULongNameEntry()</pre>
<div class="block">Indicate if this entry is a GNU long name block</div>
<dl><dt><span class="strong">Returns:</span></dt><dd>true if this is a long name extension provided by GNU tar</dd></dl>
</li>
</ul>
<a name="isDirectory()">
<!--   -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>isDirectory</h4>
<pre>public&nbsp;boolean&nbsp;isDirectory()</pre>
<div class="block">Return whether or not this entry represents a directory.</div>
<dl><dt><span class="strong">Returns:</span></dt><dd>True if this entry is a directory.</dd></dl>
</li>
</ul>
<a name="getDirectoryEntries()">
<!--   -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>getDirectoryEntries</h4>
<pre>public&nbsp;<a href="../../../../org/apache/tools/tar/TarEntry.html" title="class in org.apache.tools.tar">TarEntry</a>[]&nbsp;getDirectoryEntries()</pre>
<div class="block">If this entry represents a file, and the file is a directory, return
 an array of TarEntries for this entry's children.</div>
<dl><dt><span class="strong">Returns:</span></dt><dd>An array of TarEntry's for this entry's children.</dd></dl>
</li>
</ul>
<a name="writeEntryHeader(byte[])">
<!--   -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>writeEntryHeader</h4>
<pre>public&nbsp;void&nbsp;writeEntryHeader(byte[]&nbsp;outbuf)</pre>
<div class="block">Write an entry's header information to a header buffer.</div>
<dl><dt><span class="strong">Parameters:</span></dt><dd><code>outbuf</code> - The tar entry header buffer to fill in.</dd></dl>
</li>
</ul>
<a name="parseTarHeader(byte[])">
<!--   -->
</a>
<ul class="blockListLast">
<li class="blockList">
<h4>parseTarHeader</h4>
<pre>public&nbsp;void&nbsp;parseTarHeader(byte[]&nbsp;header)</pre>
<div class="block">Parse an entry's header information from a header buffer.</div>
<dl><dt><span class="strong">Parameters:</span></dt><dd><code>header</code> - The tar entry header buffer to get information from.</dd></dl>
</li>
</ul>
</li>
</ul>
</li>
</ul>
</div>
</div>
<!-- ========= END OF CLASS DATA ========= -->
<!-- ======= START OF BOTTOM NAVBAR ====== -->
<div class="bottomNav"><a name="navbar_bottom">
<!--   -->
</a><a href="#skip-navbar_bottom" title="Skip navigation links"></a><a name="navbar_bottom_firstrow">
<!--   -->
</a>
<ul class="navList" title="Navigation">
<li><a href="../../../../overview-summary.html">Overview</a></li>
<li><a href="package-summary.html">Package</a></li>
<li class="navBarCell1Rev">Class</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><a href="../../../../org/apache/tools/tar/TarConstants.html" title="interface in org.apache.tools.tar"><span class="strong">Prev Class</span></a></li>
<li><a href="../../../../org/apache/tools/tar/TarInputStream.html" title="class in org.apache.tools.tar"><span class="strong">Next Class</span></a></li>
</ul>
<ul class="navList">
<li><a href="../../../../index.html?org/apache/tools/tar/TarEntry.html" target="_top">Frames</a></li>
<li><a href="TarEntry.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>
<div>
<ul class="subNavList">
<li>Summary:&nbsp;</li>
<li>Nested&nbsp;|&nbsp;</li>
<li><a href="#field_summary">Field</a>&nbsp;|&nbsp;</li>
<li><a href="#constructor_summary">Constr</a>&nbsp;|&nbsp;</li>
<li><a href="#method_summary">Method</a></li>
</ul>
<ul class="subNavList">
<li>Detail:&nbsp;</li>
<li><a href="#field_detail">Field</a>&nbsp;|&nbsp;</li>
<li><a href="#constructor_detail">Constr</a>&nbsp;|&nbsp;</li>
<li><a href="#method_detail">Method</a></li>
</ul>
</div>
<a name="skip-navbar_bottom">
<!--   -->
</a></div>
<!-- ======== END OF BOTTOM NAVBAR ======= -->
</body>
</html>