hep.io.hbook
Class HbookFile

java.lang.Object
  extended by hep.io.hbook.HbookFile

public class HbookFile
extends Object

Class for reading an HBook/PAW file.

Version:
$Id: HbookFile.java 8584 2006-08-10 23:06:37Z duns $
Author:
tonyj

Constructor Summary
HbookFile(File file)
          Open an hbook file.
HbookFile(String fileName)
          Open an hbook file.
HbookFile(String fileName, int recordSize)
          Open an hbook file.
 
Method Summary
 void close()
          Close the file.
 CompositeHbookObject getTopLevelDirectory()
          Returns the top level directory for this file.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

HbookFile

public HbookFile(File file)
          throws IOException
Open an hbook file.

Parameters:
file - The file to open
Throws:
IOException - If an IOError occurs while opening the file

HbookFile

public HbookFile(String fileName)
          throws IOException
Open an hbook file.

Parameters:
fileName - The name of the file to open
Throws:
IOException - If an IOError occurs while opening the file

HbookFile

public HbookFile(String fileName,
                 int recordSize)
          throws IOException
Open an hbook file.

Parameters:
fileName - The name of the file to open
recordSize - The record size (0 for default)
Throws:
IOException - If an IOError occurs while opening the file
Method Detail

close

public void close()
           throws IOException
Close the file. No more operations can be performed on the file or any of the objects obtained from the file after it is closed.

Throws:
IOException - If an IOError occurs while closing the file

getTopLevelDirectory

public CompositeHbookObject getTopLevelDirectory()
Returns the top level directory for this file. Use this to access objects inside the HBook file.

Returns:
The CompositeHbookObject representing the top level directory


Copyright © 2000-2007 FreeHEP. All Rights Reserved.