Class GanttViewConfiguration

java.lang.Object
overit.geocallapp.utilities.ux.ui.container.gantt.view.GanttViewConfiguration
All Implemented Interfaces:
Serializable
Direct Known Subclasses:
DataCollectionTemplateGanttViewConfiguration, ForecastActivityDetailGanttViewConfiguration, ProjectGanttViewConfiguration

public class GanttViewConfiguration extends Object implements Serializable
Allow to store all the visualization configuration for the GanttView
See Also:
  • Field Details

    • HOUR

      public static final int HOUR
      See Also:
    • DAY

      public static final int DAY
      See Also:
    • WEEK

      public static final int WEEK
      See Also:
    • MONTH

      public static final int MONTH
      See Also:
    • QUARTERS

      public static final int QUARTERS
      See Also:
    • THIRDS

      public static final int THIRDS
      See Also:
    • YEAR

      public static final int YEAR
      See Also:
    • DEFAULT_MINUTE_WIDTH_FOR_HOUR

      public static final double DEFAULT_MINUTE_WIDTH_FOR_HOUR
      See Also:
    • DEFAULT_MINUTE_WIDTH_FOR_DAY

      public static final double DEFAULT_MINUTE_WIDTH_FOR_DAY
      See Also:
    • DEFAULT_MINUTE_WIDTH_FOR_WEEK

      public static final double DEFAULT_MINUTE_WIDTH_FOR_WEEK
      See Also:
    • DEFAULT_MINUTE_WIDTH_FOR_MONTH

      public static final double DEFAULT_MINUTE_WIDTH_FOR_MONTH
      See Also:
    • DEFAULT_MINUTE_WIDTH_FOR_QUORTER

      public static final double DEFAULT_MINUTE_WIDTH_FOR_QUORTER
      See Also:
    • DEFAULT_MINUTE_WIDTH_FOR_THIRDS

      public static final double DEFAULT_MINUTE_WIDTH_FOR_THIRDS
      See Also:
    • DEFAULT_MINUTE_WIDTH_FOR_YEAR

      public static final double DEFAULT_MINUTE_WIDTH_FOR_YEAR
      See Also:
    • _visibleRangeBegin

      protected Date _visibleRangeBegin
    • _visibleRangeEnd

      protected Date _visibleRangeEnd
    • _headerGroupRows

      protected List<Integer> _headerGroupRows
    • _widthForHour

      protected double _widthForHour
    • _widthForDay

      protected double _widthForDay
    • _widthForWeek

      protected double _widthForWeek
    • _widthForMonth

      protected double _widthForMonth
    • _widthForQuarter

      protected double _widthForQuarter
    • _widthForFourMonths

      protected double _widthForFourMonths
    • _widthForYear

      protected double _widthForYear
    • _brickType

      protected int _brickType
    • _minuteWidth

      protected double _minuteWidth
    • _rowHeight

      protected int _rowHeight
    • _indicatorWidth

      protected int _indicatorWidth
    • _indicatorDistance

      protected int _indicatorDistance
    • _preferenceName

      protected String _preferenceName
    • _showGridRows

      protected boolean _showGridRows
    • _showGridCols

      protected boolean _showGridCols
    • _showExpectedBlocks

      protected boolean _showExpectedBlocks
    • _showActualBlocks

      protected boolean _showActualBlocks
    • _showIndicators

      protected boolean _showIndicators
    • _showRelations

      protected boolean _showRelations
    • _showStatusColors

      protected boolean _showStatusColors
  • Constructor Details

    • GanttViewConfiguration

      public GanttViewConfiguration()
  • Method Details

    • setMinuteWidth

      public void setMinuteWidth(double minuteWidth)
      Allow to modify the width of a brick in the GanttView
      Parameters:
      minuteWidth - the width of a brick of the Gantt expressed in pixel
    • setRowHeight

      public void setRowHeight(int rowHeight)
      Allow to modify the height of a row in the GanttView
      Parameters:
      rowHeight - the height of a Gantt row expressed in pixel
    • getMinuteWidth

      public double getMinuteWidth()
      Returns:
      width of a brick in the GanttView expressed in pixel
    • getRowHeight

      public int getRowHeight()
      Returns:
      the height of a row in the GanttView expressed in pixel
    • getIndicatorWidth

      public int getIndicatorWidth()
    • setIndicatorWidth

      public void setIndicatorWidth(int indicatorWidth)
    • getIndicatorDistance

      public int getIndicatorDistance()
    • setIndicatorDistance

      public void setIndicatorDistance(int indicatorDistance)
    • setBrickType

      public void setBrickType(int type)
      Allow to define the brick type. Valid values are
          HOUR
          DAY
          WEEK
          MONTH
          QUARTERS
          THIRDS
          YEAR
       
      Parameters:
      type - the brick type
    • getBrickType

      public int getBrickType()
      Returns:
      the brick type Valid values are
          HOUR
          DAY
          WEEK
          MONTH
          QUARTERS
          THIRDS
          YEAR
       
    • setVisibleRangeBegin

      public void setVisibleRangeBegin(Date visibleRangeBegin)
      Define the visualization begin date
      Parameters:
      visibleRangeBegin - the begin date to show in the GanttView
    • getVisibleRangeBegin

      public Date getVisibleRangeBegin()
      Returns:
      the begin date to show in the GanttView
    • setVisibleRangeEnd

      public void setVisibleRangeEnd(Date visibleRangeEnd)
      Define the end of the visualization window for the GanttView
      Parameters:
      visibleRangeEnd - the visualization end date
    • getVisibleRangeEnd

      public Date getVisibleRangeEnd()
      Returns:
      the visualization end date
    • setHeaderGroupRows

      public void setHeaderGroupRows(int... rowType)
      Allow to define a set of brick type to use as extra header to group the main brick type. For example: if the main brick type is DAY and add MONTH the gantt will present the month header over the day header
       -----------------------March--------------------------|
       ----01----|----02----|----03----|----04----|----05----|
       
      Parameters:
      rowType - the header group rows
    • getHeaderGroupRows

      public List<Integer> getHeaderGroupRows()
      Returns:
      an unmodifiable list with the brick types to use as extra header to group the main brick type.
    • getHeaderRowNumber

      public int getHeaderRowNumber()
      Returns:
      the number of extra headers defined
    • getBrickWidthPreferences

      protected State.Conf getBrickWidthPreferences(String preferenceName)
    • updateBrickWidths

      protected void updateBrickWidths(String widthString)
      Parameters:
      widthString - a sequence of widths separated by comma to update the brick widths. Used mainly to restore the saved user preference the string must have this order hour,day,week,month,year
    • getBrickWidthsString

      protected String getBrickWidthsString()
    • setPreferenceName

      public void setPreferenceName(String name)
    • alignBrickWidth

      protected void alignBrickWidth()
    • getDefaultMinuteWidth

      public double getDefaultMinuteWidth(int type)
    • isShowExpectedBlocks

      public boolean isShowExpectedBlocks()
    • setShowExpectedBlocks

      public void setShowExpectedBlocks(boolean showExpectedBlocks)
    • isShowActualBlocks

      public boolean isShowActualBlocks()
    • setShowActualBlocks

      public void setShowActualBlocks(boolean showActualBlocks)
    • isShowIndicators

      public boolean isShowIndicators()
    • setShowIndicators

      public void setShowIndicators(boolean showIndicators)
    • isShowRelations

      public boolean isShowRelations()
    • setShowRelations

      public void setShowRelations(boolean showRelations)
    • isShowStatusColors

      public boolean isShowStatusColors()
    • setShowStatusColors

      public void setShowStatusColors(boolean showStatusColors)
    • isShowGridRows

      public boolean isShowGridRows()
    • setShowGridRows

      public void setShowGridRows(boolean gridRows)
    • isShowGridCols

      public boolean isShowGridCols()
    • setShowGridCols

      public void setShowGridCols(boolean gridCols)