com.dlsc.flexgantt.policy.layer

## Class TimeGranularityGridLinePolicy

- java.lang.Object
- - com.dlsc.flexgantt.policy.AbstractPolicy
  - - com.dlsc.flexgantt.policy.layer.DefaultGridLinePolicy
    - - com.dlsc.flexgantt.policy.layer.TimeGranularityGridLinePolicy

- All Implemented Interfaces:
    IPolicy, IGridLinePolicy

      public class TimeGranularityGridLinePolicy
      extends DefaultGridLinePolicy

  A specialization of the default grid line policy for situations where the `TimeGranularityDatelineModel` gets used by the dateline. This policy takes into account that depending on the major and the minor time granularities the major and minor grid lines will not be on top of each other causing a messy grid line appearance. In these cases the policy will turn off the major grid lines. For a more general description of this policy please refer to the policy interface `IGridLinePolicy`.
  Since:
    1.0
  Version:
    $Revision: 1.4 $
  Author:
    Dirk Lemmermann

- - ### Constructor Summary

    Constructors
    Constructor and Description
    `TimeGranularityGridLinePolicy()`

  - ### Method Summary

    All Methods Instance Methods Concrete Methods
    Modifier and Type | Method and Description
    --- | ---
    `boolean` | `isMajorGridLinesVisible(IDatelineModel datelineModel, GridLineMode mode)` Determines whether the grid lines for the major time units will be shown or not.

    - ### Methods inherited from class com.dlsc.flexgantt.policy.layer.DefaultGridLinePolicy

      `isMinorGridLinesVisible`

    - ### Methods inherited from class com.dlsc.flexgantt.policy.AbstractPolicy

      `assertClass`

    - ### Methods inherited from class java.lang.Object

      `clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

- - ### Constructor Detail

    - #### TimeGranularityGridLinePolicy

          public TimeGranularityGridLinePolicy()

  - ### Method Detail

    - #### isMajorGridLinesVisible

          public boolean isMajorGridLinesVisible(IDatelineModel datelineModel,
                                                 GridLineMode mode)

      Description copied from interface: `IGridLinePolicy`
      Determines whether the grid lines for the major time units will be shown or not.
      Specified by:
        `isMajorGridLinesVisible` in interface `IGridLinePolicy`
      Overrides:
        `isMajorGridLinesVisible` in class `DefaultGridLinePolicy`
      Parameters:
        `datelineModel` - the dateline model currently used by the dateline
        `mode` - the grid mode (show no grid, minor grid, major grid, combined grid)
      Returns:
        TRUE if the grid lines for the major time unit are visible

Copyright © 2006–2020 Dirk Lemmermann Software & Consulting. All rights reserved.