DecompoundedWord implements Comparable<DecompoundedWord> { public boolean isCompound() { return splits.size() != 1; }  static DecompoundedWord createFromString(String aSplit); @Override int hashCode(); @Override boolean equals(Object obj); @Override String toString(); void appendSplitElement(Fragment aSplit); void prependSplitElement(Fragment aSplit); List<Fragment> getSplits(); void setSplits(List<Fragment> aSplits); void addAll(List<Fragment> aSplits); void replaceSplitElement(int aIndex, DecompoundedWord aSplit); void replaceSplitElement(int aIndex, Fragment aSplitElement); boolean equalWithoutMorpheme(DecompoundedWord aOtherSplit); String getWord(); DecompoundedWord createCopy(); double getWeight(); void setWeight(double aWeight); @Override int compareTo(DecompoundedWord aOtherSplit); void setSplitPos(int aSplitPos); int getSplitPos(); boolean isCompound(); boolean hasLastFragmentMorpheme();  }
@Test public void testIsCompound() { DecompoundedWord s1 = DecompoundedWord.createFromString("Aktion(s)+plan"); DecompoundedWord s2 = DecompoundedWord.createFromString("Aktionsplan"); assertThat(s1.isCompound()).isTrue(); assertThat(s2.isCompound()).isFalse(); }