com.lizardtech.djvu
Class DjVmDir.File

java.lang.Object
  extended by com.lizardtech.djvu.DjVmDir.File
All Implemented Interfaces:
java.lang.Cloneable
Enclosing class:
DjVmDir

public static final class DjVmDir.File
extends java.lang.Object
implements java.lang.Cloneable

This class stores the details about a single page of include file within a document.

Version:
$Revision: 1.3 $
Author:
Bill C. Riemers

Field Summary
static byte INCLUDE
          flag to indicate an include file
 int offset
          The position of this file in the main document.
static byte PAGE
          flag to indicate a page
static byte SHARED_ANNO
          flag to indicate shared annotations
 int size
          The size of this file.
static byte THUMBNAILS
          flag to indicate thumbnails
 
Constructor Summary
DjVmDir.File()
          Creates a new File object.
DjVmDir.File(java.lang.String load_name, java.lang.String save_name, java.lang.String title, int file_type)
          Creates a new File object.
 
Method Summary
 java.lang.Object clone()
          Create a clone of this object
 java.lang.String get_load_name()
          Query the load name (id) of this file.
 int get_page_num()
          Query the page number of this file.
 java.lang.String get_save_name()
          Query the save name (name) of this file.
 java.lang.String get_str_type()
          Query a description of the file type.
 java.lang.String get_title()
          Query the title of this file.
 boolean is_include()
          Query if this is an include file.
 boolean is_page()
          Query if this is a page.
 boolean is_shared_anno()
          Query if this is a shared annotation
 boolean is_thumbnails()
          Query if this is a thumbnail.
 void set_load_name(java.lang.String id)
          Set the load name (id) of this file.
protected  void set_save_name(java.lang.String name)
          Set the save name (name) of this file.
 void set_title(java.lang.String title)
          Set the title of this page.
 
Methods inherited from class java.lang.Object
equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

INCLUDE

public static final byte INCLUDE
flag to indicate an include file

See Also:
Constant Field Values

PAGE

public static final byte PAGE
flag to indicate a page

See Also:
Constant Field Values

THUMBNAILS

public static final byte THUMBNAILS
flag to indicate thumbnails

See Also:
Constant Field Values

SHARED_ANNO

public static final byte SHARED_ANNO
flag to indicate shared annotations

See Also:
Constant Field Values

offset

public int offset
The position of this file in the main document.


size

public int size
The size of this file.

Constructor Detail

DjVmDir.File

public DjVmDir.File()
Creates a new File object.


DjVmDir.File

public DjVmDir.File(java.lang.String load_name,
                    java.lang.String save_name,
                    java.lang.String title,
                    int file_type)
Creates a new File object.

Parameters:
load_name - the load name (id) of this file
save_name - the save name (name) of this file
title - the title of this file
file_type - the type of file
Method Detail

clone

public java.lang.Object clone()
Create a clone of this object

Overrides:
clone in class java.lang.Object
Returns:
the newly created clone

get_load_name

public final java.lang.String get_load_name()
Query the load name (id) of this file.

Returns:
the load name

get_save_name

public final java.lang.String get_save_name()
Query the save name (name) of this file.

Returns:
the save name

get_title

public final java.lang.String get_title()
Query the title of this file.

Returns:
the title

get_page_num

public final int get_page_num()
Query the page number of this file.

Returns:
page number or -1

get_str_type

public java.lang.String get_str_type()
                              throws java.io.IOException
Query a description of the file type.

Returns:
a String describing the file type.
Throws:
java.io.IOException - if an error occurs

is_include

public boolean is_include()
Query if this is an include file.

Returns:
true if this is an include file

is_page

public boolean is_page()
Query if this is a page.

Returns:
true if this is a page

is_shared_anno

public boolean is_shared_anno()
Query if this is a shared annotation

Returns:
true if this is a shared annotation

is_thumbnails

public boolean is_thumbnails()
Query if this is a thumbnail.

Returns:
true if this is a thumbnail

set_load_name

public void set_load_name(java.lang.String id)
Set the load name (id) of this file.

Parameters:
id - the load name to use

set_title

public void set_title(java.lang.String title)
Set the title of this page.

Parameters:
title - the page title

set_save_name

protected void set_save_name(java.lang.String name)
Set the save name (name) of this file.

Parameters:
name - save name to use