|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectca.uottawa.balie.NamedEntityType
public class NamedEntityType
Type of a NE
Constructor Summary | |
---|---|
NamedEntityType(int pi_TagSetSize,
NamedEntityExplanation pi_Info)
Construct a new, empty, entity type |
|
NamedEntityType(NamedEntityTypeEnumI pi_Type,
int pi_TagSetSize,
NamedEntityExplanation pi_Info)
Construct a new entity type and set its type to a primitive |
Method Summary | |
---|---|
void |
AddType(NamedEntityTypeEnumI pi_Type,
NamedEntityExplanation pi_Info)
Add a primitive type to this entity type (e.g. add LOCATION) An entity can have multiple types |
NamedEntityType |
clone(NamedEntityExplanation pi_Info)
|
boolean |
equals(java.lang.Object pi_Obj)
|
java.util.ArrayList<java.lang.String> |
GetAllLabels(NamedEntityTypeEnumI[] pi_Types)
|
java.lang.String |
GetInfo()
Get explanations about this named entity |
java.lang.String |
GetLabel(NamedEntityTypeEnumI[] pi_Types)
Get a label for the current entity. |
int |
hashCode()
|
boolean |
HasNoTag()
Check if this entity has no primitive types |
boolean |
Intersect(NamedEntityType pi_NE)
Check types that are common to this entity and the parameter entity |
static NamedEntityType |
Intersection(NamedEntityType pi_NE1,
NamedEntityType pi_NE2,
NamedEntityExplanation pi_Info)
Returns a entity that is the intersection of the two parameters |
boolean |
IsA(NamedEntityTypeEnumI pi_Type)
Check if this entity has the given primitive type |
boolean |
IsEnd()
Check if this entity ends an expression (equivalent to IsA(NETypes.END)) |
boolean |
IsStart()
Check if this entity dtarts an expression (equivalent to IsA(NETypes.START)) |
void |
KeepOnly(NamedEntityType pi_NE,
NamedEntityExplanation pi_Info)
Keeps only the primitive types whose correspond to a type in the parameter entity Equivalent to bitwise AND |
void |
MergeWith(NamedEntityType pi_NE,
NamedEntityExplanation pi_Info)
Merge primitive type of current and parameter entity Equivalent to bitwise OR |
void |
RemoveType(NamedEntityTypeEnumI pi_Type,
NamedEntityExplanation pi_Info)
Remove a primitive type from this entity Succeed even if this entity do not have this type |
int |
TypeCount()
Get the number of primitive types declared in this entity |
void |
WipeInfo()
|
Methods inherited from class java.lang.Object |
---|
getClass, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
---|
public NamedEntityType(int pi_TagSetSize, NamedEntityExplanation pi_Info)
pi_TagSetSize
- size of NE tag setpublic NamedEntityType(NamedEntityTypeEnumI pi_Type, int pi_TagSetSize, NamedEntityExplanation pi_Info)
pi_Type
- primitive typeMethod Detail |
---|
public NamedEntityType clone(NamedEntityExplanation pi_Info)
public void AddType(NamedEntityTypeEnumI pi_Type, NamedEntityExplanation pi_Info)
pi_Type
- primitive typepublic void RemoveType(NamedEntityTypeEnumI pi_Type, NamedEntityExplanation pi_Info)
pi_Type
- primitive typepublic boolean Intersect(NamedEntityType pi_NE)
pi_NE
- an entity
public static NamedEntityType Intersection(NamedEntityType pi_NE1, NamedEntityType pi_NE2, NamedEntityExplanation pi_Info)
pi_NE1
- an entitypi_NE2
- another entity
public void KeepOnly(NamedEntityType pi_NE, NamedEntityExplanation pi_Info)
pi_NE
- an entitypublic void MergeWith(NamedEntityType pi_NE, NamedEntityExplanation pi_Info)
pi_NE
- an entity to merge withpublic java.lang.String GetLabel(NamedEntityTypeEnumI[] pi_Types)
public java.util.ArrayList<java.lang.String> GetAllLabels(NamedEntityTypeEnumI[] pi_Types)
public java.lang.String GetInfo()
public void WipeInfo()
public boolean IsA(NamedEntityTypeEnumI pi_Type)
pi_Type
- primitive type
public boolean IsStart()
public boolean IsEnd()
public boolean HasNoTag()
public int TypeCount()
public boolean equals(java.lang.Object pi_Obj)
equals
in class java.lang.Object
public int hashCode()
hashCode
in class java.lang.Object
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |