Class PMDB

java.lang.Object
  |
  +--PMDB

public class PMDB
extends java.lang.Object

This class represents the settings for the use of PageMaker.

Author:
John E. Darrow (c) 2000, 2001

Field Summary
static java.lang.String ALLPICSSORTCAPTSTR
           
static java.lang.String ALLPICSSORTCONTRSTR
           
static java.lang.String ALLPICSSORTDATESTR
           
static java.lang.String ALLPICSSORTSUBJECTSTR
           
static java.lang.String ALLPICSSTR
           
protected static java.util.Vector alteredFiles
          A list of pictures and categories for which web pages should be generated.
static java.lang.String bkgdImage
          The image to be used as the background of all web pages.
protected static java.util.Vector capRetrieverExclusionList
          List of catLinks to exclude when gathering captions.
protected static java.util.Hashtable catBlurbsHT
          All available category descriptions/blurbs.
protected static java.util.Hashtable catLinksHT
          All of the CatLinks.
static int COLWIDTH
          The maximum number of characters for word wraps.
protected static java.lang.String curLang
          The language for the pages being generated at this moment.
protected static java.lang.Class defaultCatLinkClass
          The subclass of CatLinks that is the base class of all other catLinks.
static java.lang.String defLang
          The primary language (for example, "en" for English).
static java.lang.String EDPICKSSTR
           
protected static HTMLWordWrap hww
          A text formatter for word wraps.
static CatIndex indexLink
          The main index page.
protected static LanguageHandler langHandler
          The handler corresponding to curLang.
protected static java.util.Hashtable langHandlers
          The collection of available LangHandlers.
protected static java.lang.String[] langs
          All languages for which the web pages can be generated (for example, "en", "de").
protected static java.lang.String[] langsToProcess
          All languages to which the web pages are to be generated (for example, "de").
static int maxPicsPerPage
          The maximum number of thumbnail pics allowed per page before dividing the pics among multiple pages.
protected static java.util.Hashtable nonStdCatLinkClasses
          The Classes of all CatLink subclasses that are different from defaultCatLinkClass.
protected static java.util.Hashtable picLinksHT
          All of the PicLinks.
protected static java.util.Vector picNames
          The selected picture filenames for which web pages are to be generated.
protected static ProcessOptions po
          Settings that determine how web pages are to be generated for this run.
static java.lang.String RECADDSTR
          The titles of the special category pages.
protected static java.util.Hashtable storiesHT
          All available stories.
protected static java.util.Hashtable transTables
          The available translation tables.
static java.lang.Class webPageClass
          The subclass of WebPage to be used for these web pages.
 
Constructor Summary
PMDB()
           
 
Method Summary
static void addNonStdCatLinkClass(java.lang.String key, java.lang.String classname)
          Creates a Class object for classname and puts it in the nonStdCatLinkClasses hashtable with key.
static void addToCapRetrieverExclusionList(java.lang.String fullCaption)
          Establishes which catLinks should be excluded when captions are being gathered for all catLinks.
static void changeLang(java.lang.String newLang)
          Changes over to the new language, such as by loading the translation tables appropriate to that new language.
protected static void fromFilesToRelationships()
          Loads the pictures and categories from file and builds relationships.
static java.lang.Class getClass(java.lang.String name)
           
protected static void loadTranslationFile(java.lang.String propsKey, java.lang.String file)
          Loads translation data from the file into a Properties table and stores the table in transTables via propsKey.
protected static void picLinksToFile(java.lang.String outFile)
          Converts all PicLinks to Strings and writes them to file.
static void setDefaultCatLinkClass(java.lang.String name)
          Establishes the Class which is to be the defaultCatLinkClass.
static void setLangs(java.lang.String[] newLangs)
          Establishes what languages are available.
static void setLangsToProcess(java.lang.String[] newLangs)
          Establishes the languages nto which the web pages are to be generated.
static void setNonStdCatLinkClasses(java.util.Hashtable ht)
          Establishes which Class objects are associated with which category names.
static void setWebPageClass(java.lang.String name)
          Establishes the Class which is to be the defaultCatLinkClass.
protected static void storiesToFile(java.lang.String outFile)
          Writes all picLink filenames and their stories to file.
protected static java.lang.String translate(java.util.Properties props, java.lang.String lookup)
          Returns the translated phrase for the specified lookup phrase appropriate for the current language and the specified translation table.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

defLang

public static java.lang.String defLang
The primary language (for example, "en" for English).

indexLink

public static CatIndex indexLink
The main index page.

RECADDSTR

public static java.lang.String RECADDSTR
The titles of the special category pages.

EDPICKSSTR

public static java.lang.String EDPICKSSTR

ALLPICSSTR

public static java.lang.String ALLPICSSTR

ALLPICSSORTCAPTSTR

public static java.lang.String ALLPICSSORTCAPTSTR

ALLPICSSORTSUBJECTSTR

public static java.lang.String ALLPICSSORTSUBJECTSTR

ALLPICSSORTCONTRSTR

public static java.lang.String ALLPICSSORTCONTRSTR

ALLPICSSORTDATESTR

public static java.lang.String ALLPICSSORTDATESTR

maxPicsPerPage

public static int maxPicsPerPage
The maximum number of thumbnail pics allowed per page before dividing the pics among multiple pages.

COLWIDTH

public static int COLWIDTH
The maximum number of characters for word wraps.

bkgdImage

public static java.lang.String bkgdImage
The image to be used as the background of all web pages.

webPageClass

public static java.lang.Class webPageClass
The subclass of WebPage to be used for these web pages.

defaultCatLinkClass

protected static java.lang.Class defaultCatLinkClass
The subclass of CatLinks that is the base class of all other catLinks.

po

protected static ProcessOptions po
Settings that determine how web pages are to be generated for this run.

curLang

protected static java.lang.String curLang
The language for the pages being generated at this moment.

langHandler

protected static LanguageHandler langHandler
The handler corresponding to curLang.

langs

protected static java.lang.String[] langs
All languages for which the web pages can be generated (for example, "en", "de").

langsToProcess

protected static java.lang.String[] langsToProcess
All languages to which the web pages are to be generated (for example, "de").

langHandlers

protected static java.util.Hashtable langHandlers
The collection of available LangHandlers.

transTables

protected static java.util.Hashtable transTables
The available translation tables.

nonStdCatLinkClasses

protected static java.util.Hashtable nonStdCatLinkClasses
The Classes of all CatLink subclasses that are different from defaultCatLinkClass.

catLinksHT

protected static java.util.Hashtable catLinksHT
All of the CatLinks. Key is the full caption, where the full caption includes a colon and caption of the parent, if this is a subcategory. For example, "Grandparent:Parent:Child"

storiesHT

protected static java.util.Hashtable storiesHT
All available stories. Key is the picture filename. Element is the story.

catBlurbsHT

protected static java.util.Hashtable catBlurbsHT
All available category descriptions/blurbs. Key is the full category caption (see catLinksHT. Element is the blurb.

picLinksHT

protected static java.util.Hashtable picLinksHT
All of the PicLinks. Key is the picture filename. Element is the picLink.

picNames

protected static java.util.Vector picNames
The selected picture filenames for which web pages are to be generated.

hww

protected static HTMLWordWrap hww
A text formatter for word wraps.

alteredFiles

protected static java.util.Vector alteredFiles
A list of pictures and categories for which web pages should be generated.

capRetrieverExclusionList

protected static java.util.Vector capRetrieverExclusionList
List of catLinks to exclude when gathering captions.
Constructor Detail

PMDB

public PMDB()
Method Detail

setLangs

public static void setLangs(java.lang.String[] newLangs)
Establishes what languages are available.

setLangsToProcess

public static void setLangsToProcess(java.lang.String[] newLangs)
Establishes the languages nto which the web pages are to be generated.

setDefaultCatLinkClass

public static void setDefaultCatLinkClass(java.lang.String name)
Establishes the Class which is to be the defaultCatLinkClass.

setWebPageClass

public static void setWebPageClass(java.lang.String name)
Establishes the Class which is to be the defaultCatLinkClass.

getClass

public static java.lang.Class getClass(java.lang.String name)

setNonStdCatLinkClasses

public static void setNonStdCatLinkClasses(java.util.Hashtable ht)
Establishes which Class objects are associated with which category names.
Parameters:
ht - The keys are the names of the classes and the elements are the Class objects for the classes.

addNonStdCatLinkClass

public static void addNonStdCatLinkClass(java.lang.String key,
                                         java.lang.String classname)
Creates a Class object for classname and puts it in the nonStdCatLinkClasses hashtable with key.

changeLang

public static void changeLang(java.lang.String newLang)
Changes over to the new language, such as by loading the translation tables appropriate to that new language.

loadTranslationFile

protected static void loadTranslationFile(java.lang.String propsKey,
                                          java.lang.String file)
Loads translation data from the file into a Properties table and stores the table in transTables via propsKey.

addToCapRetrieverExclusionList

public static void addToCapRetrieverExclusionList(java.lang.String fullCaption)
Establishes which catLinks should be excluded when captions are being gathered for all catLinks.

fromFilesToRelationships

protected static void fromFilesToRelationships()
Loads the pictures and categories from file and builds relationships.

storiesToFile

protected static void storiesToFile(java.lang.String outFile)
Writes all picLink filenames and their stories to file. If there is no story, only the picLink name is written.

picLinksToFile

protected static void picLinksToFile(java.lang.String outFile)
Converts all PicLinks to Strings and writes them to file.

translate

protected static java.lang.String translate(java.util.Properties props,
                                            java.lang.String lookup)
Returns the translated phrase for the specified lookup phrase appropriate for the current language and the specified translation table.