ca.site.elkb
Class Category

java.lang.Object
  extended by ca.site.elkb.Category

public class Category
extends java.lang.Object

Represents the Roget's Thesaurus Tabular Synopsis of Categories. The topmost level of this ontology divides the Thesaurus into eight Classes:

  1. Abstract Relations
  2. Space
  3. Matter
  4. Intellect: the exercise of the mind (Formation of ideas)
  5. Intellect: the exercise of the mind (Communication of ideas)
  6. Volition: the exercise of the will (Individual volition)
  7. Volition: the exercise of the will (Social volition)
  8. Emotion, religion and morality

Classes are further divided into Sections, Sub-sections, Head groups, and Heads.

Version:
1.4 2013
Author:
Mario Jarmasz and Alistsair Kennedy

Constructor Summary
Category()
          Default Constructor
Category(java.lang.String filename)
          Constructor that builds the Category object using the information contained in a file.
 
Method Summary
 void addToClassList(RogetClass rtClass)
          adds to classList
 void addToHeadList(HeadInfo rogetHead)
          adds a RogetHead to the headList.
 void classCountIncrement()
          Increments class Count
 int getClassCount()
          Returns the number of Roget's Classes in this ontology.
 java.util.ArrayList<RogetClass> getClassList()
          Returns the array of RogetClass objects.
 int getHeadCount()
          Returns the number of Heads in this ontology.
 int getHeadGroupCount()
          Returns the number of Head groups in this ontology.
 HeadInfo getHeadInfo(int headNum)
          Returns the array of HeadInfo objects.
 java.util.ArrayList<HeadInfo> getHeadList()
          Returns the array of HeadInfo objects.
 RogetClass getRogetClass(int index)
          Returns the Roget's Class at the specified position in the array of Classes.
 int getSectionCount()
          Returns the number of Sections in this ontology.
 int getSubSectionCount()
          Returns the number of Sub-sections in this ontology.
 void headCountIncrement()
          increments headCount
 void headGroupCountIncrement()
          Increments head group count.
 void printHeadInfo()
          Prints the array of HeadInfo objects to the standard output.
 void printRogetClass(int index)
          Prints the Roget's Class at the specified position in the array of Classes to the standard output.
 void sectionCountIncrement()
          Increments Section count.
 void subSectionCountIncrement()
          Increments subSection count.
 java.lang.String toString()
          Converts to a string representation the Category object.
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Constructor Detail

Category

public Category()
Default Constructor


Category

public Category(java.lang.String filename)
Constructor that builds the Category object using the information contained in a file. The default file for the ELKB is rogetMap.rt contained in the $HOME/roget_elkb directory.

Parameters:
filename -
Method Detail

getClassCount

public int getClassCount()
Returns the number of Roget's Classes in this ontology.


getSectionCount

public int getSectionCount()
Returns the number of Sections in this ontology.

Returns:
section count

getSubSectionCount

public int getSubSectionCount()
Returns the number of Sub-sections in this ontology.

Returns:
subsection count

getHeadGroupCount

public int getHeadGroupCount()
Returns the number of Head groups in this ontology.

Returns:
number of head groups

getHeadCount

public int getHeadCount()
Returns the number of Heads in this ontology.

Returns:
number of heads

getRogetClass

public RogetClass getRogetClass(int index)
Returns the Roget's Class at the specified position in the array of Classes.

Parameters:
index -
Returns:
RogetClass

printRogetClass

public void printRogetClass(int index)
Prints the Roget's Class at the specified position in the array of Classes to the standard output.

Parameters:
index -

getClassList

public java.util.ArrayList<RogetClass> getClassList()
Returns the array of RogetClass objects.

Returns:
ArrayList of classes

getHeadList

public java.util.ArrayList<HeadInfo> getHeadList()
Returns the array of HeadInfo objects.

Returns:
ArrayList of heads

getHeadInfo

public HeadInfo getHeadInfo(int headNum)
Returns the array of HeadInfo objects.

Returns:
ArrayList of heads

printHeadInfo

public void printHeadInfo()
Prints the array of HeadInfo objects to the standard output.


toString

public java.lang.String toString()
Converts to a string representation the Category object. The following following format is used - Category:classCount:sectionCount:subSectionCount:headGroupCount:headCount.

Overrides:
toString in class java.lang.Object

classCountIncrement

public void classCountIncrement()
Increments class Count


addToClassList

public void addToClassList(RogetClass rtClass)
adds to classList

Parameters:
rtClass -

subSectionCountIncrement

public void subSectionCountIncrement()
Increments subSection count.


headGroupCountIncrement

public void headGroupCountIncrement()
Increments head group count.


addToHeadList

public void addToHeadList(HeadInfo rogetHead)
adds a RogetHead to the headList.

Parameters:
rogetHead -

sectionCountIncrement

public void sectionCountIncrement()
Increments Section count.


headCountIncrement

public void headCountIncrement()
increments headCount