ch.claudio.fat
Class DirectoryEntry

java.lang.Object
  extended by ch.claudio.fat.DirectoryEntry

public class DirectoryEntry
extends java.lang.Object

Version:
$Id:$
Author:
Claudio Nieder

Copyright (C) 2007 Claudio Nieder <private@claudio.ch>, CH-8610 Uster

This program is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation; version 2 of the License.

This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details.

You should have received a copy of the GNU General Public License along with this program; if not, write to the Free Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA


Field Summary
 long accessTime
           
 byte attributes
           
 long creationTime
           
static int entrySize
          Size in byte of a directory entry.
 java.lang.String extension
           
 int fileSize
           
 int firstCluster
           
 java.lang.String longname
           
 long modificationTime
           
 java.lang.String name
           
 int slots
          Number of slots used in the block.
 
Constructor Summary
DirectoryEntry()
           
 
Method Summary
static DirectoryEntry create(byte[] b, int off)
          Create an instance filled from the block.
 void fillin(byte[] b, int offset)
          Fill in from the block.
static void main(java.lang.String[] args)
          Print license.
 java.lang.String toString()
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Field Detail

entrySize

public static final int entrySize
Size in byte of a directory entry.

See Also:
Constant Field Values

name

public java.lang.String name

extension

public java.lang.String extension

longname

public java.lang.String longname

attributes

public byte attributes

creationTime

public long creationTime

accessTime

public long accessTime

modificationTime

public long modificationTime

firstCluster

public int firstCluster

fileSize

public int fileSize

slots

public int slots
Number of slots used in the block. Just 1 for entries without a long name, otherwise >1.

Constructor Detail

DirectoryEntry

public DirectoryEntry()
Method Detail

fillin

public void fillin(byte[] b,
                   int offset)
            throws java.io.UnsupportedEncodingException
Fill in from the block.

Parameters:
b - block
offset - offset
Throws:
java.io.UnsupportedEncodingException

create

public static DirectoryEntry create(byte[] b,
                                    int off)
                             throws java.io.UnsupportedEncodingException
Create an instance filled from the block.

Parameters:
b - block
off - offset
Returns:
directory entry
Throws:
java.io.UnsupportedEncodingException

toString

public java.lang.String toString()
Overrides:
toString in class java.lang.Object
See Also:
Object.toString()

main

public static void main(java.lang.String[] args)
Print license.

Parameters:
args - ignored