tagLocation = BinaryTools.readUInt32AsLong(myInputStream);
myInputStream.close();
myInputStream = null;
}
catch (IOException myIOException) {
throw new HandlerException(myIOException);
}
finally {
if (myInputStream != null) {
try {
myInputStream.close();
}
catch (IOException myIOException) {
}
}
}
FileEntry myFileEntry = new FileEntry();
myFileEntry.DescriptorTag.TagSerialNumber = tagSerialNumber;
myFileEntry.DescriptorTag.DescriptorVersion = descriptorVersion;
myFileEntry.DescriptorTag.TagLocation = tagLocation;
myFileEntry.Uid = 0xFFFFFFFF; // TODO: get current uid and gid if java supports it
myFileEntry.Gid = 0xFFFFFFFF;
// TODO: get real file permission if java supports it
myFileEntry.Permissions = Permissions.OTHER_Read | Permissions.GROUP_Read | Permissions.OWNER_Read;
myFileEntry.FileLinkCount = fileLinkCount;
myFileEntry.RecordFormat = 0;
myFileEntry.RecordDisplayAttributes = 0;
myFileEntry.RecordLength = 0;
myFileEntry.AccessTime = new Timestamp(accessTime);
myFileEntry.ModificationTime = new Timestamp(modificationTime);
myFileEntry.AttributeTime = new Timestamp(attributeTime);
myFileEntry.Checkpoint = 1;
try {
myFileEntry.ImplementationIdentifier.setIdentifier(applicationIdentifier);
}
catch (Exception myException) {
throw new HandlerException(myException);
}
myFileEntry.ImplementationIdentifier.IdentifierSuffix = applicationIdentifierSuffix;
myFileEntry.ICBTag.PriorRecordedNumberofDirectEntries = 0;