Class AbstractCalendarItem

java.lang.Object
io.goobi.viewer.model.calendar.AbstractCalendarItem
All Implemented Interfaces:
ICalendarItem, Comparable<ICalendarItem>
Direct Known Subclasses:
CalendarItemCentury, CalendarItemDay, CalendarItemMonth, CalendarItemWeek, CalendarItemYear

public abstract class AbstractCalendarItem extends Object implements ICalendarItem

Abstract AbstractCalendarItem class.

  • Field Details

    • name

      protected String name
    • value

      protected int value
    • hits

      protected int hits
    • selected

      protected boolean selected
  • Constructor Details

    • AbstractCalendarItem

      protected AbstractCalendarItem()
      No-arg constructor.
    • AbstractCalendarItem

      protected AbstractCalendarItem(String name, int value, int hits)

      Constructor for AbstractCalendarItem.

      Parameters:
      name - a String object.
      value - a int.
      hits - a int.
  • Method Details

    • getName

      public String getName()

      getName.

      Specified by:
      getName in interface ICalendarItem
      Returns:
      a String object.
    • getValue

      public int getValue()

      getValue.

      Specified by:
      getValue in interface ICalendarItem
      Returns:
      a int.
    • getFormattedValue

      public String getFormattedValue()
      Returns a two-digit string representation of this item's value.
      Returns:
      a String object.
    • getHits

      public int getHits()

      getHits.

      Specified by:
      getHits in interface ICalendarItem
      Returns:
      a int.
    • setHits

      public void setHits(int hits)

      setHits.

      Specified by:
      setHits in interface ICalendarItem
      Parameters:
      hits - a int.
    • isSelected

      public boolean isSelected()

      isSelected.

      Specified by:
      isSelected in interface ICalendarItem
      Returns:
      a boolean.
    • setSelected

      public void setSelected(boolean selected)

      setSelected.

      Specified by:
      setSelected in interface ICalendarItem
      Parameters:
      selected - a boolean.
    • isEmpty

      public boolean isEmpty()
    • addHits

      public void addHits(Integer additionalHits)