story.scheherazade.misc
Class NounType

java.lang.Object
  extended by story.scheherazade.misc.GenericScheherID
      extended by story.scheherazade.misc.NounType
All Implemented Interfaces:
java.lang.Comparable, RenderableObject, ScheherIDWithType
Direct Known Subclasses:
BehaviorType, CharacterType, GenericNounType, LocationType, PropType, QualityType

public class NounType
extends GenericScheherID
implements ScheherIDWithType

An class for GenericScheherIDs for the noun type classes in particular (locationType, propType, characterType).


Field Summary
static NodeID GROUP_BEHAVIOR_NODEID
           
static NodeID GROUP_CHARACTER_NODEID
           
static NodeID GROUP_LOCATION_NODEID
           
static NodeID GROUP_PROP_NODEID
           
static NodeID PROTOTYPE_BEHAVIOR_NODEID
           
static NodeID PROTOTYPE_CHARACTER_NODEID
           
static NodeID PROTOTYPE_LOCATION_NODEID
           
static NodeID PROTOTYPE_NOUN_NODEID
           
static NodeID PROTOTYPE_PROP_NODEID
           
static NodeID PROTOTYPE_QUALITY_NODEID
           
 
Constructor Summary
NounType(NounFlavor flavor, java.lang.String name)
           
NounType(NounType noun, NounType supertype, java.lang.String menuName, WordNetOffset offset, java.lang.String pluralForm, boolean proper, PropDiscreteness discreteness, CharacterGender gender)
          Constructor that adds metadata to a basic descriptor.
 
Method Summary
static boolean allowsGroups(NounFlavor flavor)
           
 int compareTo(java.lang.Object other)
           
static java.lang.String getBoundaryString(NounFlavor flavor)
           
 PropDiscreteness getDiscreteness()
           
 CharacterGender getGender()
           
static NodeAddress getGroupNodeAddress(NounFlavor flavor)
           
static NounType getGroupNounType(NounFlavor flavor)
           
 java.lang.String getMenuName()
           
 NounFlavor getNounFlavor()
           
static LinkType getNounFlavorDeclarationLinkType(NounFlavor flavor)
           
static LinkType getNounFlavorDefinitionLinkType(NounFlavor flavor)
           
static NodeID getNounFlavorPrototypeNodeID(NounFlavor flavor)
           
 java.lang.String getPluralForm()
           
 boolean getProper()
           
 GenericScheherID getType()
          Get the GenericScheherID's type (or supertype, if it's already a type).
static NodeAddress getUniversalNodeAddress(NounFlavor flavor)
           
static NounType getUniversalNounType(NounFlavor flavor)
           
 WordNetOffset getWordNetOffset()
          Get the GenericScheherID's WordNet synset offset
 boolean isCompleteType()
          Returns true if this is a complete descriptor, with plural form, proper, and other metadata.
 java.lang.StringBuffer render()
          Render the ID in a StringBuffer.
 
Methods inherited from class story.scheherazade.misc.GenericScheherID
equals, getIDType, isEveryType, isGenericType, isGroupType, isUniversalType, toRawString, toString
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, wait, wait, wait
 
Methods inherited from interface story.scheherazade.misc.ScheherIDWithType
isUniversalType
 

Field Detail

PROTOTYPE_CHARACTER_NODEID

public static final NodeID PROTOTYPE_CHARACTER_NODEID

PROTOTYPE_PROP_NODEID

public static final NodeID PROTOTYPE_PROP_NODEID

PROTOTYPE_LOCATION_NODEID

public static final NodeID PROTOTYPE_LOCATION_NODEID

PROTOTYPE_QUALITY_NODEID

public static final NodeID PROTOTYPE_QUALITY_NODEID

PROTOTYPE_BEHAVIOR_NODEID

public static final NodeID PROTOTYPE_BEHAVIOR_NODEID

GROUP_CHARACTER_NODEID

public static final NodeID GROUP_CHARACTER_NODEID

GROUP_LOCATION_NODEID

public static final NodeID GROUP_LOCATION_NODEID

GROUP_PROP_NODEID

public static final NodeID GROUP_PROP_NODEID

GROUP_BEHAVIOR_NODEID

public static final NodeID GROUP_BEHAVIOR_NODEID

PROTOTYPE_NOUN_NODEID

public static final NodeID PROTOTYPE_NOUN_NODEID
Constructor Detail

NounType

public NounType(NounFlavor flavor,
                java.lang.String name)
         throws Scheherexception
Throws:
Scheherexception

NounType

public NounType(NounType noun,
                NounType supertype,
                java.lang.String menuName,
                WordNetOffset offset,
                java.lang.String pluralForm,
                boolean proper,
                PropDiscreteness discreteness,
                CharacterGender gender)
         throws Scheherexception
Constructor that adds metadata to a basic descriptor.

Throws:
Scheherexception
Method Detail

isCompleteType

public boolean isCompleteType()
Returns true if this is a complete descriptor, with plural form, proper, and other metadata. Returns false if just a name.


render

public java.lang.StringBuffer render()
                              throws Scheherexception
Description copied from class: GenericScheherID
Render the ID in a StringBuffer. Automatically punctuates according to ID type.

Specified by:
render in interface RenderableObject
Specified by:
render in class GenericScheherID
Throws:
Scheherexception

compareTo

public int compareTo(java.lang.Object other)
              throws java.lang.ClassCastException
Specified by:
compareTo in interface java.lang.Comparable
Overrides:
compareTo in class GenericScheherID
Throws:
java.lang.ClassCastException

getType

public GenericScheherID getType()
                         throws Scheherexception
Description copied from interface: ScheherIDWithType
Get the GenericScheherID's type (or supertype, if it's already a type).

Specified by:
getType in interface ScheherIDWithType
Throws:
Scheherexception

getNounFlavor

public NounFlavor getNounFlavor()

getWordNetOffset

public WordNetOffset getWordNetOffset()
                               throws Scheherexception
Description copied from interface: ScheherIDWithType
Get the GenericScheherID's WordNet synset offset

Specified by:
getWordNetOffset in interface ScheherIDWithType
Throws:
Scheherexception

getDiscreteness

public PropDiscreteness getDiscreteness()
                                 throws Scheherexception
Throws:
Scheherexception

getGender

public CharacterGender getGender()
                          throws Scheherexception
Throws:
Scheherexception

getMenuName

public java.lang.String getMenuName()
                             throws Scheherexception
Throws:
Scheherexception

getPluralForm

public java.lang.String getPluralForm()
                               throws Scheherexception
Throws:
Scheherexception

getProper

public boolean getProper()
                  throws Scheherexception
Throws:
Scheherexception

getBoundaryString

public static java.lang.String getBoundaryString(NounFlavor flavor)
                                          throws Scheherexception
Throws:
Scheherexception

getUniversalNodeAddress

public static NodeAddress getUniversalNodeAddress(NounFlavor flavor)
                                           throws Scheherexception
Throws:
Scheherexception

getGroupNodeAddress

public static NodeAddress getGroupNodeAddress(NounFlavor flavor)
                                       throws Scheherexception
Throws:
Scheherexception

getUniversalNounType

public static NounType getUniversalNounType(NounFlavor flavor)
                                     throws Scheherexception
Throws:
Scheherexception

getGroupNounType

public static NounType getGroupNounType(NounFlavor flavor)
                                 throws Scheherexception
Throws:
Scheherexception

allowsGroups

public static boolean allowsGroups(NounFlavor flavor)
                            throws Scheherexception
Throws:
Scheherexception

getNounFlavorPrototypeNodeID

public static NodeID getNounFlavorPrototypeNodeID(NounFlavor flavor)
                                           throws Scheherexception
Throws:
Scheherexception

getNounFlavorDeclarationLinkType

public static LinkType getNounFlavorDeclarationLinkType(NounFlavor flavor)
                                                 throws Scheherexception
Throws:
Scheherexception

getNounFlavorDefinitionLinkType

public static LinkType getNounFlavorDefinitionLinkType(NounFlavor flavor)
                                                throws Scheherexception
Throws:
Scheherexception


Copyright © 2011 David K. Elson. All Rights Reserved.