|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object ch.uzh.ifi.attempto.base.DefaultTextOperator
public class DefaultTextOperator
This class is the default implementation of a text operator.
Constructor Summary | |
---|---|
DefaultTextOperator()
|
Method Summary | |
---|---|
TextElement |
createTextElement(java.lang.String text)
This method should create a text element for the given text. |
java.lang.String |
getGlue(TextElement left,
TextElement right)
This method should return the "glue" to connect two text elements. |
java.lang.String |
getTextInContext(TextElement textElement,
java.lang.String preceding,
java.lang.String following)
This method checks the context of a text element and can do small surface adaptations of a token according to the surrounding text. |
java.util.List<java.lang.String> |
splitIntoTokens(java.lang.String text)
This method should split a text into its tokens. |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
---|
public DefaultTextOperator()
Method Detail |
---|
public TextElement createTextElement(java.lang.String text)
TextOperator
createTextElement
in interface TextOperator
text
- The text.
public java.lang.String getTextInContext(TextElement textElement, java.lang.String preceding, java.lang.String following)
TextOperator
getTextInContext
in interface TextOperator
textElement
- The text element whose text should be adapted to the context.preceding
- The preceding text.following
- The following text.
public java.util.List<java.lang.String> splitIntoTokens(java.lang.String text)
TextOperator
splitIntoTokens
in interface TextOperator
text
- The input text.
public java.lang.String getGlue(TextElement left, TextElement right)
TextOperator
getGlue
in interface TextOperator
left
- The left-hand side text element.right
- The right-hand side text element.
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |