edu.northwestern.at.morphadorner.tei

## Class TEIHeaderInfo

- java.lang.Object
- - edu.northwestern.at.morphadorner.tei.TEIHeaderInfo

-     public class TEIHeaderInfo
      extends java.lang.Object

  Extract selected "teiHeader" information from a TEI file.

- - ### Field Summary

    Fields
    Modifier and Type | Field and Description
    --- | ---
    `protected java.util.List<TEIHeaderAuthor>` | `authorList` List of authors.
    `protected java.util.Map<java.lang.String,java.lang.String>` | `authorMap` Current author map.
    `(package private) java.lang.String` | `fileName` File name.
    `(package private) java.lang.String` | `title` Title.

  - ### Constructor Summary

    Constructors
    Constructor and Description
    `TEIHeaderInfo(java.lang.String teiXMLFileName)` Get bibliographic information from TEI header section.

  - ### Method Summary

    Methods
    Modifier and Type | Method and Description
    --- | ---
    `java.util.List<TEIHeaderAuthor>` | `getAuthors()` Return author list.
    `java.lang.String` | `getFileName()` Get file name.
    `java.lang.String` | `getTitle()` Get title.
    `protected static boolean` | `isAuthor(java.lang.String name)` Determine if this is an author element or not.
    `protected static boolean` | `isBiblFull(java.lang.String name)` Determine if this is a biblFull element or not.
    `protected static boolean` | `isTitle(java.lang.String name)` Determine if this is a title element or not.
    `protected static boolean` | `isTitleStmt(java.lang.String name)` Determine if this is a titleStmt element or not.
    `protected void` | `parseXML(java.lang.String xmlFile)` Parse adorned file.
    `protected java.lang.String` | `safeString(java.lang.String s)` Return string ensuring null is set to empty string.

    - ### Methods inherited from class java.lang.Object

      `clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

- - ### Field Detail

    - #### fileName

          java.lang.String fileName

      File name.

    - #### title

          java.lang.String title

      Title.

    - #### authorList

          protected java.util.List<TEIHeaderAuthor> authorList

      List of authors.

    - #### authorMap

          protected java.util.Map<java.lang.String,java.lang.String> authorMap

      Current author map.

  - ### Constructor Detail

    - #### TEIHeaderInfo

          public TEIHeaderInfo(java.lang.String teiXMLFileName)

      Get bibliographic information from TEI header section.
      Parameters:
        `teiXMLFileName` - The TEI XML file name.

  - ### Method Detail

    - #### getFileName

          public java.lang.String getFileName()

      Get file name.
      Returns:
        The file name.

    - #### getTitle

          public java.lang.String getTitle()

      Get title.
      Returns:
        The work's title.

    - #### getAuthors

          public java.util.List<TEIHeaderAuthor> getAuthors()

      Return author list.
      Returns:
        authorList List of author maps.

    - #### parseXML

          protected void parseXML(java.lang.String xmlFile)

      Parse adorned file.
      Parameters:
        `xmlFile` - Bibadorned XML file name.

    - #### isBiblFull

          protected static boolean isBiblFull(java.lang.String name)

      Determine if this is a biblFull element or not.
      Parameters:
        `name` - tag name
      Returns:
        true if tag name is "biblFull".

    - #### isTitleStmt

          protected static boolean isTitleStmt(java.lang.String name)

      Determine if this is a titleStmt element or not.
      Parameters:
        `name` - tag name
      Returns:
        true if tag name is "titleStmt".

    - #### isTitle

          protected static boolean isTitle(java.lang.String name)

      Determine if this is a title element or not.
      Parameters:
        `name` - tag name
      Returns:
        true if tag name is "title".

    - #### isAuthor

          protected static boolean isAuthor(java.lang.String name)

      Determine if this is an author element or not.
      Parameters:
        `name` - tag name
      Returns:
        true if tag name is "author".

    - #### safeString

          protected java.lang.String safeString(java.lang.String s)

      Return string ensuring null is set to empty string.
      Parameters:
        `s` - String to check.
      Returns:
        Original value of "s" if s is not null, or empty string if "s" is null.