Class StopwordsItem

java.lang.Object
org.codelibs.fess.dict.DictionaryItem
org.codelibs.fess.dict.stopwords.StopwordsItem

public class StopwordsItem extends DictionaryItem
Represents an item in a stopwords dictionary. This class stores a stopword and tracks its updated value.
  • Constructor Details

    • StopwordsItem

      public StopwordsItem(long id, String input)
      Constructs a new stopword item.
      Parameters:
      id - The unique identifier of the item.
      input - The stopword.
  • Method Details

    • getNewInput

      public String getNewInput()
      Gets the new stopword.
      Returns:
      The new stopword.
    • setNewInput

      public void setNewInput(String newInput)
      Sets the new stopword.
      Parameters:
      newInput - The new stopword.
    • getInput

      public String getInput()
      Gets the original stopword.
      Returns:
      The original stopword.
    • getInputValue

      public String getInputValue()
      Gets the value of the stopword.
      Returns:
      The stopword value, or an empty string if null.
    • isUpdated

      public boolean isUpdated()
      Checks if the item has been updated.
      Returns:
      true if the item has been updated, false otherwise.
    • isDeleted

      public boolean isDeleted()
      Checks if the item has been marked for deletion.
      Returns:
      true if the item is marked for deletion, false otherwise.
    • hashCode

      public int hashCode()
      Overrides:
      hashCode in class Object
    • equals

      public boolean equals(Object obj)
      Overrides:
      equals in class Object
    • toString

      public String toString()
      Overrides:
      toString in class Object
    • toLineString

      public String toLineString()
      Converts the item to a string representation for writing to a file.
      Returns:
      The stopword as a string.