org.at4j.tar
Class TarEntryHeaderData

java.lang.Object
  extended by org.at4j.tar.TarEntryHeaderData
All Implemented Interfaces:
TarEntryHeader

public final class TarEntryHeaderData
extends Object
implements TarEntryHeader

This object contains data that is found in a Tar header.

Since:
1.0
Author:
Karl Gustafsson

Constructor Summary
TarEntryHeaderData()
           
 
Method Summary
 int getChecksum()
           
 int getDevMajor()
           
 int getDevMinor()
           
 long getFileSize()
           
 Date getLastModificationTime()
           
 String getLinkName()
           
 AbsoluteLocation getLocation()
           
 String getMagic()
           
 UnixEntityMode getMode()
           
 int getOwnerGid()
           
 String getOwnerGroupName()
           
 int getOwnerUid()
           
 String getOwnerUserName()
           
 char getTypeFlag()
          Get the type flag for the entry.
 String getUstarVersion()
           
 Map<String,String> getVariables()
           
 boolean isDirectory()
           
 void setChecksum(int checksum)
           
 void setDevMajor(int devMajor)
           
 void setDevMinor(int devMinor)
           
 void setDirectory(boolean directory)
           
 void setFileSize(long fileSize)
           
 void setGroupName(String groupName)
           
 void setLastModificationTime(Date lastModificationTime)
           
 void setLinkName(String linkName)
           
 void setLocation(AbsoluteLocation location)
           
 void setMagic(String magic)
           
 void setMode(UnixEntityMode mode)
           
 void setOwnerGid(int ownerGid)
           
 void setOwnerName(String ownerName)
           
 void setOwnerUid(int ownerUid)
           
 void setTypeFlag(char typeFlag)
           
 void setUstarVersion(String ustarVersion)
           
 void setVariables(Map<String,String> variables)
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

TarEntryHeaderData

public TarEntryHeaderData()
Method Detail

getLocation

public AbsoluteLocation getLocation()

setLocation

public void setLocation(AbsoluteLocation location)

getMode

public UnixEntityMode getMode()

setMode

public void setMode(UnixEntityMode mode)

getOwnerUid

public int getOwnerUid()

setOwnerUid

public void setOwnerUid(int ownerUid)

getOwnerGid

public int getOwnerGid()

setOwnerGid

public void setOwnerGid(int ownerGid)

getFileSize

public long getFileSize()

setFileSize

public void setFileSize(long fileSize)

getLastModificationTime

public Date getLastModificationTime()

setLastModificationTime

public void setLastModificationTime(Date lastModificationTime)

getChecksum

public int getChecksum()

setChecksum

public void setChecksum(int checksum)

getTypeFlag

public char getTypeFlag()
Get the type flag for the entry. This may be '0' ( TarConstants.FILE_TYPE_FLAG) or '\0' ( TarConstants.ALT_FILE_TYPE_FLAG) for a file, '5' ( TarConstants.DIRECTORY_TYPE_FLAG) for a directory or '2' (TarConstants.SYMBOLIC_LINK_TYPE_FLAG) for a symbolic link. In the case of directories, the isDirectory() method should preferably be used since the type flag does not seem to always be set.


setTypeFlag

public void setTypeFlag(char typeFlag)

getLinkName

public String getLinkName()

setLinkName

public void setLinkName(String linkName)

getMagic

public String getMagic()

setMagic

public void setMagic(String magic)

getUstarVersion

public String getUstarVersion()

setUstarVersion

public void setUstarVersion(String ustarVersion)

getOwnerUserName

public String getOwnerUserName()

setOwnerName

public void setOwnerName(String ownerName)

getOwnerGroupName

public String getOwnerGroupName()

setGroupName

public void setGroupName(String groupName)

getDevMajor

public int getDevMajor()

setDevMajor

public void setDevMajor(int devMajor)

getDevMinor

public int getDevMinor()

setDevMinor

public void setDevMinor(int devMinor)

isDirectory

public boolean isDirectory()

setDirectory

public void setDirectory(boolean directory)

getVariables

public Map<String,String> getVariables()

setVariables

public void setVariables(Map<String,String> variables)