All Packages  Class Hierarchy  This Package  Previous  Next  Index

Class edu.vt.marian.Document.SimpleDocument

java.lang.Object
   |
   +----edu.vt.marian.common.FullID
           |
           +----edu.vt.marian.Document.SimpleDocument

public class SimpleDocument
extends FullID
implements Document
Sort of the natural solution to the interface: a Document that can do all and only the interface methods with the minimum of overhead.


Constructor Index

 o SimpleDocument(Debug)
Create a null SimpleDocument object.
 o SimpleDocument(Debug, String)
Create a SimpleDocument object.
 o SimpleDocument(Debug, String, String)
Create a SimpleDocument object from just a short and a long description.
 o SimpleDocument(Debug, String, String, String)
Create a SimpleDocument object.

Method Index

 o attributes()
return a Vector of metadata attributes for this document.
 o copy()
An attempt to get around declaring public clone() methods.
 o isValid()
Is this object ready to rock? Yes.
 o presentAttribute(int, int)
Return an Object (almost certainly a String) in some markupType for the given attribute.
 o presentAttributes(int)
return a Vector of metadata attributes for this document.
 o presentFull(int)
return the full description of this document.
 o presentFull(int, BufferedWriter)
 o presentLong(int)
return the long description of this document.
 o presentLong(int, BufferedWriter)
 o presentShort(int)
return the short description of this document in one line.
 o presentShort(int, BufferedWriter)

Constructors

 o SimpleDocument
 public SimpleDocument(Debug dbg,
                       String shDesc,
                       String lgDesc,
                       String flDesc)
Create a SimpleDocument object.

Parameters:
shDesc - short description.
lgDesc - long description.
flDesc - full description.
 o SimpleDocument
 public SimpleDocument(Debug dbg,
                       String shDesc,
                       String lgDesc)
Create a SimpleDocument object from just a short and a long description.

Parameters:
shDesc - short description.
lgDesc - long description.
 o SimpleDocument
 public SimpleDocument(Debug dbg,
                       String shDesc)
Create a SimpleDocument object.

Parameters:
shDesc - short description.
 o SimpleDocument
 public SimpleDocument(Debug dbg)
Create a null SimpleDocument object.

Methods

 o isValid
 public boolean isValid()
Is this object ready to rock? Yes.

Overrides:
isValid in class FullID
 o copy
 public DigInfObj copy()
An attempt to get around declaring public clone() methods.

 o presentShort
 public String presentShort(int markupType)
return the short description of this document in one line.

Parameters:
markupType - how to mark up the string returned (e.g., HTML or ASCII).
Returns:
the short description String.
 o presentShort
 public int presentShort(int markupType,
                         BufferedWriter out) throws IOException
 o presentLong
 public String presentLong(int markupType)
return the long description of this document.

Parameters:
markupType - how to mark up the string returned (e.g., HTML or ASCII).
Returns:
a (potentially very long) String.
 o presentLong
 public int presentLong(int markupType,
                        BufferedWriter out) throws IOException
 o presentFull
 public String presentFull(int markupType)
return the full description of this document.

Parameters:
markupType - how to mark up the string returned (e.g., HTML or ASCII).
Returns:
a (potentially very long) String.
 o presentFull
 public int presentFull(int markupType,
                        BufferedWriter out) throws IOException
 o presentAttributes
 public Vector presentAttributes(int markupType)
return a Vector of metadata attributes for this document.

Parameters:
markupType - how to mark up the string returned (e.g., HTML or ASCII).
Returns:
a Vector of triples [attrName, attrType, attrValue].
 o presentAttribute
 public Object presentAttribute(int attrID,
                                int markupType)
Return an Object (almost certainly a String) in some markupType for the given attribute.

Parameters:
markupType - how to mark up the string returned (e.g., HTML or ASCII).
Returns:
a Vector of triples [attrName, attrType, attrValue].
 o attributes
 public Vector attributes()
return a Vector of metadata attributes for this document.

Parameters:
markupType - how to mark up the string returned (e.g., HTML or ASCII).
Returns:
a Vector of triples [attrName, attrType, attrValue].

All Packages  Class Hierarchy  This Package  Previous  Next  Index