Package com.basistech.rosette.dm
Class MorphoAnalysis
java.lang.Object
com.basistech.rosette.dm.BaseAttribute
com.basistech.rosette.dm.MorphoAnalysis
- All Implemented Interfaces:
Serializable
- Direct Known Subclasses:
ArabicMorphoAnalysis
,HanMorphoAnalysis
,KoreanMorphoAnalysis
A MorphoAnalysis contains all the results of analyzing a word, or something like a word.
This data model assumes that, presented with a token, an analyzer will produce one or more analyses,
where each analysis is a coordinated collection of attributes. The simplest example is a part-of-speech tag
and a lemma, but some languages yield more data.
This one class contains the basic attributes that are more or less common to the languages supported by Rosette Base Linguistics. There are subclasses for some specific languages.
In some languages, words are decompounded into pieces that can, themselves, be analyzed.
This one class contains the basic attributes that are more or less common to the languages supported by Rosette Base Linguistics. There are subclasses for some specific languages.
In some languages, words are decompounded into pieces that can, themselves, be analyzed.
- See Also:
-
Nested Class Summary
Modifier and TypeClassDescriptionstatic class
MorphoAnalysis.Builder<T extends MorphoAnalysis,
B extends MorphoAnalysis.Builder<T, B>> Builder forMorphoAnalysis
. -
Field Summary
Fields inherited from class com.basistech.rosette.dm.BaseAttribute
extendedProperties
-
Constructor Summary
ModifierConstructorDescriptionprotected
MorphoAnalysis
(String partOfSpeech, String lemma, List<Token> components, String raw, TagSet tagSet, Map<String, Object> extendedProperties) Creates an analysis.protected
MorphoAnalysis
(String partOfSpeech, String lemma, List<Token> components, String raw, Map<String, Object> extendedProperties) Creates an analysis. -
Method Summary
Methods inherited from class com.basistech.rosette.dm.BaseAttribute
getExtendedProperties, listOrNull, setExtendedProperty
-
Constructor Details
-
MorphoAnalysis
protected MorphoAnalysis(String partOfSpeech, String lemma, List<Token> components, String raw, TagSet tagSet, Map<String, Object> extendedProperties) Creates an analysis.- Parameters:
partOfSpeech
- part-of-speechlemma
- the lemmacomponents
- compound componentsraw
- raw analysistagSet
- the tag setextendedProperties
- extended properties
-
MorphoAnalysis
protected MorphoAnalysis(String partOfSpeech, String lemma, List<Token> components, String raw, Map<String, Object> extendedProperties) Creates an analysis.- Parameters:
partOfSpeech
- part-of-speechlemma
- the lemmacomponents
- compound componentsraw
- raw analysisextendedProperties
- extended properties
-
-
Method Details
-
getPartOfSpeech
Returns the part-of-speech.- Returns:
- the part-of-speech
-
getLemma
Returns the lemma.- Returns:
- the lemma
-
getComponents
Returns the compound components.- Returns:
- the compound components
-
getRaw
Returns the raw analysis. The raw analysis is a language and analyzer-specific string, typically used to convey debug-level information. Applications should usually not depend on the raw analysis.- Returns:
- the raw analysis
-
getTagSet
Returns the tag set.- Returns:
- the tag set
-
toStringHelper
protected com.google.common.base.MoreObjects.ToStringHelper toStringHelper()- Overrides:
toStringHelper
in classBaseAttribute
-
toString
- Overrides:
toString
in classBaseAttribute
-