public class DecompoundedWord extends Object implements Comparable<DecompoundedWord>
Constructor and Description |
---|
DecompoundedWord() |
Modifier and Type | Method and Description |
---|---|
void |
addAll(List<Fragment> aSplits)
Adds a list of split elements.
|
void |
appendSplitElement(Fragment aSplit)
Adds a split element at the end
|
int |
compareTo(DecompoundedWord aOtherSplit) |
DecompoundedWord |
createCopy()
Creates a copy of this element.
|
static DecompoundedWord |
createFromString(String aSplit)
Create a split from a string
The string has the structure: word1(morpheme)+word2(morpheme)+...+word3
For example: "Aktion(s)+plan" or "Verbraucher+zahlen"
|
boolean |
equals(Object obj) |
boolean |
equalWithoutMorpheme(DecompoundedWord aOtherSplit)
Similar to the equals method, but combines morpheme and word
|
int |
getSplitPos() |
List<Fragment> |
getSplits()
Returns all split elements
|
double |
getWeight()
Returns the ranked weight of the split
|
String |
getWord()
Returns the complete word without + or ()
|
int |
hashCode() |
boolean |
hasLastFragmentMorpheme()
Checks if last fragment has a linking morpheme.
|
boolean |
isCompound()
Checks if this instance is a compounding word.
|
void |
prependSplitElement(Fragment aSplit)
Adds a split element to the beginning
|
void |
replaceSplitElement(int aIndex,
DecompoundedWord aSplit)
Replace one split element with a split.
|
void |
replaceSplitElement(int aIndex,
Fragment aSplitElement)
Replaces a split element with another one
|
void |
setSplitPos(int aSplitPos) |
void |
setSplits(List<Fragment> aSplits)
Set all split elements
|
void |
setWeight(double aWeight)
Sets a rank weight for the split
|
String |
toString() |
public static DecompoundedWord createFromString(String aSplit)
public void appendSplitElement(Fragment aSplit)
public void prependSplitElement(Fragment aSplit)
public void replaceSplitElement(int aIndex, DecompoundedWord aSplit)
public void replaceSplitElement(int aIndex, Fragment aSplitElement)
public boolean equalWithoutMorpheme(DecompoundedWord aOtherSplit)
public String getWord()
public DecompoundedWord createCopy()
public double getWeight()
public void setWeight(double aWeight)
public int compareTo(DecompoundedWord aOtherSplit)
compareTo
in interface Comparable<DecompoundedWord>
public void setSplitPos(int aSplitPos)
public int getSplitPos()
public boolean isCompound()
public boolean hasLastFragmentMorpheme()
Copyright © 2011–2015. All rights reserved.