Class Grids

    • Constructor Detail

      • Grids

        public Grids()
        Constructor, all grid types enabled per property configurations
      • Grids

        public Grids​(GridType... types)
        Constructor
        Parameters:
        types - grid types to enable
      • Grids

        public Grids​(Collection<GridType> types)
        Constructor
        Parameters:
        types - grid types to enable
    • Method Detail

      • create

        public static Grids create()
        Create with all grid types enabled
        Returns:
        grids
      • create

        public static Grids create​(GridType... types)
        Create with grids to enable
        Parameters:
        types - grid types to enable
        Returns:
        grids
      • create

        public static Grids create​(Collection<GridType> types)
        Create with grids to enable
        Parameters:
        types - grid types to enable
        Returns:
        grids
      • createGZD

        public static Grids createGZD()
        Create only Grid Zone Designator grids
        Returns:
        grids
      • newGrid

        protected Grid newGrid​(GridType type)
        Create a new grid, override to create a specialized grid
        Parameters:
        type - grid type
        Returns:
        grid
      • getGrid

        public Grid getGrid​(GridType type)
        Get the grid
        Parameters:
        type - grid type
        Returns:
        grid
      • getPrecision

        public GridType getPrecision​(int zoom)
        Get the grid precision for the zoom level
        Parameters:
        zoom - zoom level
        Returns:
        grid type precision
      • setGrids

        public void setGrids​(GridType... types)
        Set the active grid types
        Parameters:
        types - grid types
      • setGrids

        public void setGrids​(Grid... grids)
        Set the active grids
        Parameters:
        grids - grids
      • setGridTypes

        public void setGridTypes​(Collection<GridType> types)
        Set the active grid types
        Parameters:
        types - grid types
      • setGrids

        public void setGrids​(Collection<Grid> grids)
        Set the active grids
        Parameters:
        grids - grids
      • enableTypes

        public void enableTypes​(GridType... types)
        Enable grid types
        Parameters:
        types - grid types
      • enableTypes

        public void enableTypes​(Collection<GridType> types)
        Enable grid types
        Parameters:
        types - grid types
      • disableTypes

        public void disableTypes​(GridType... types)
        Disable grid types
        Parameters:
        types - grid types
      • disableTypes

        public void disableTypes​(Collection<GridType> types)
        Disable grid types
        Parameters:
        types - grid types
      • isEnabled

        public boolean isEnabled​(GridType type)
        Is the grid type enabled
        Parameters:
        type - grid type
        Returns:
        true if enabled
      • enable

        public void enable​(GridType type)
        Enable the grid type
        Parameters:
        type - grid type
      • disable

        public void disable​(GridType type)
        Disable the grid type
        Parameters:
        type - grid type
      • setMinZoom

        public void setMinZoom​(GridType type,
                               int minZoom)
        Set the grid minimum zoom
        Parameters:
        type - grid type
        minZoom - minimum zoom
      • setMaxZoom

        public void setMaxZoom​(GridType type,
                               Integer maxZoom)
        Set the grid maximum zoom
        Parameters:
        type - grid type
        maxZoom - maximum zoom
      • setZoomRange

        public void setZoomRange​(GridType type,
                                 int minZoom,
                                 Integer maxZoom)
        Set the grid zoom range
        Parameters:
        type - grid type
        minZoom - minimum zoom
        maxZoom - maximum zoom
      • setLinesMinZoom

        public void setLinesMinZoom​(GridType type,
                                    Integer minZoom)
        Set the grid minimum level override for drawing grid lines
        Parameters:
        type - grid type
        minZoom - minimum zoom level or null to remove
      • setLinesMaxZoom

        public void setLinesMaxZoom​(GridType type,
                                    Integer maxZoom)
        Set the grid maximum level override for drawing grid lines
        Parameters:
        type - grid type
        maxZoom - maximum zoom level or null to remove
      • setAllColors

        public void setAllColors​(Color color)
        Set all grid line colors
        Parameters:
        color - grid line color
      • setColor

        public void setColor​(Color color,
                             GridType... types)
        Set the grid line color for the grid types
        Parameters:
        color - grid line color
        types - grid types
      • setColor

        public void setColor​(Collection<GridType> types,
                             Color color)
        Set the grid line color for the grid types
        Parameters:
        types - grid types
        color - grid line color
      • setColor

        public void setColor​(GridType type,
                             Color color)
        Set the grid line color for the grid type
        Parameters:
        type - grid type
        color - grid line color
      • setAllWidths

        public void setAllWidths​(double width)
        Set all grid line widths
        Parameters:
        width - grid line width
      • setWidth

        public void setWidth​(double width,
                             GridType... types)
        Set the grid line width for the grid types
        Parameters:
        width - grid line width
        types - grid types
      • setWidth

        public void setWidth​(Collection<GridType> types,
                             double width)
        Set the grid line width for the grid types
        Parameters:
        types - grid types
        width - grid line width
      • setWidth

        public void setWidth​(GridType type,
                             double width)
        Set the grid line width for the grid type
        Parameters:
        type - grid type
        width - grid line width
      • deletePropagatedStyles

        public void deletePropagatedStyles()
        Delete propagated styles
      • deletePropagatedStyles

        public void deletePropagatedStyles​(GridType... types)
        Delete propagated styles for the grid types
        Parameters:
        types - grid types
      • deletePropagatedStyles

        public void deletePropagatedStyles​(Collection<GridType> types)
        Delete propagated styles for the grid types
        Parameters:
        types - grid types
      • deletePropagatedStyles

        public void deletePropagatedStyles​(GridType type)
        Delete propagated styles for the grid type
        Parameters:
        type - grid type
      • setColor

        public void setColor​(Collection<GridType> types,
                             GridType precisionType,
                             Color color)
        Set the grid type precision line color for the grid types
        Parameters:
        types - grid types
        precisionType - precision grid type
        color - grid line color
      • setColor

        public void setColor​(GridType type,
                             Color color,
                             GridType... precisionTypes)
        Set the grid type precision line colors for the grid type
        Parameters:
        type - grid type
        color - grid line color
        precisionTypes - precision grid types
      • setColor

        public void setColor​(GridType type,
                             Collection<GridType> precisionTypes,
                             Color color)
        Set the grid type precision line colors for the grid type
        Parameters:
        type - grid type
        precisionTypes - precision grid types
        color - grid line color
      • setColor

        public void setColor​(GridType type,
                             GridType precisionType,
                             Color color)
        Set the grid type precision line color for the grid type
        Parameters:
        type - grid type
        precisionType - precision grid type
        color - grid line color
      • setWidth

        public void setWidth​(Collection<GridType> types,
                             GridType precisionType,
                             double width)
        Set the grid type precision line width for the grid types
        Parameters:
        types - grid types
        precisionType - precision grid type
        width - grid line width
      • setWidth

        public void setWidth​(GridType type,
                             double width,
                             GridType... precisionTypes)
        Set the grid type precision line widths for the grid type
        Parameters:
        type - grid type
        width - grid line width
        precisionTypes - precision grid types
      • setWidth

        public void setWidth​(GridType type,
                             Collection<GridType> precisionTypes,
                             double width)
        Set the grid type precision line widths for the grid type
        Parameters:
        type - grid type
        precisionTypes - precision grid types
        width - grid line width
      • setWidth

        public void setWidth​(GridType type,
                             GridType precisionType,
                             double width)
        Set the grid type precision line width for the grid type
        Parameters:
        type - grid type
        precisionType - precision grid type
        width - grid line width
      • getLabeler

        public GridLabeler getLabeler​(GridType type)
        Get the labeler for the grid type
        Parameters:
        type - grid type
        Returns:
        labeler or null
      • hasLabeler

        public boolean hasLabeler​(GridType type)
        Has a labeler for the grid type
        Parameters:
        type - grid type
        Returns:
        true if has labeler
      • setLabeler

        public void setLabeler​(GridType type,
                               GridLabeler labeler)
        Set the labeler for the grid type
        Parameters:
        type - grid type
        labeler - labeler
      • disableAllLabelers

        public void disableAllLabelers()
        Disable all grid labelers
      • enableLabelers

        public void enableLabelers​(GridType... types)
        Enable the labelers for the grid types
        Parameters:
        types - grid types
      • enableLabelers

        public void enableLabelers​(Collection<GridType> types)
        Enable the labelers for the grid types
        Parameters:
        types - grid types
      • disableLabelers

        public void disableLabelers​(GridType... types)
        Disable the labelers for the grid types
        Parameters:
        types - grid types
      • disableLabelers

        public void disableLabelers​(Collection<GridType> types)
        Disable the labelers for the grid types
        Parameters:
        types - grid types
      • isLabelerEnabled

        public boolean isLabelerEnabled​(GridType type)
        Is a labeler enabled for the grid type
        Parameters:
        type - grid type
        Returns:
        true if labeler enabled
      • enableLabeler

        public void enableLabeler​(GridType type)
        Enable the grid type labeler
        Parameters:
        type - grid type
      • disableLabeler

        public void disableLabeler​(GridType type)
        Disable the grid type labeler
        Parameters:
        type - grid type
      • setLabelMinZoom

        public void setLabelMinZoom​(GridType type,
                                    int minZoom)
        Set the grid minimum zoom
        Parameters:
        type - grid type
        minZoom - minimum zoom
      • setLabelMaxZoom

        public void setLabelMaxZoom​(GridType type,
                                    Integer maxZoom)
        Set the grid maximum zoom
        Parameters:
        type - grid type
        maxZoom - maximum zoom
      • setLabelZoomRange

        public void setLabelZoomRange​(GridType type,
                                      int minZoom,
                                      Integer maxZoom)
        Set the grid zoom range
        Parameters:
        type - grid type
        minZoom - minimum zoom
        maxZoom - maximum zoom
      • setLabelBuffer

        public void setLabelBuffer​(double buffer,
                                   GridType... types)
        Set the label grid zone edge buffer for the grid types
        Parameters:
        buffer - label buffer (greater than or equal to 0.0 and less than 0.5)
        types - grid types
      • setLabelBuffer

        public void setLabelBuffer​(Collection<GridType> types,
                                   double buffer)
        Set the label grid zone edge buffer for the grid types
        Parameters:
        types - grid types
        buffer - label buffer (greater than or equal to 0.0 and less than 0.5)
      • getLabelBuffer

        public double getLabelBuffer​(GridType type)
        Get the label grid zone edge buffer
        Parameters:
        type - grid type
        Returns:
        label buffer (greater than or equal to 0.0 and less than 0.5)
      • setLabelBuffer

        public void setLabelBuffer​(GridType type,
                                   double buffer)
        Set the label grid zone edge buffer
        Parameters:
        type - grid type
        buffer - label buffer (greater than or equal to 0.0 and less than 0.5)
      • setAllLabelColors

        public void setAllLabelColors​(Color color)
        Set all label colors
        Parameters:
        color - label color
      • setLabelColor

        public void setLabelColor​(Color color,
                                  GridType... types)
        Set the label color for the grid types
        Parameters:
        color - label color
        types - grid types
      • setLabelColor

        public void setLabelColor​(Collection<GridType> types,
                                  Color color)
        Set the label color for the grid types
        Parameters:
        types - grid types
        color - label color
      • setLabelColor

        public void setLabelColor​(GridType type,
                                  Color color)
        Set the label color
        Parameters:
        type - grid type
        color - label color
      • setAllLabelTextSizes

        public void setAllLabelTextSizes​(double textSize)
        Set all label text sizes
        Parameters:
        textSize - label text size
      • setLabelTextSize

        public void setLabelTextSize​(double textSize,
                                     GridType... types)
        Set the label text size for the grid types
        Parameters:
        textSize - label text size
        types - grid types
      • setLabelTextSize

        public void setLabelTextSize​(Collection<GridType> types,
                                     double textSize)
        Set the label text size for the grid types
        Parameters:
        types - grid types
        textSize - label text size
      • setLabelTextSize

        public void setLabelTextSize​(GridType type,
                                     double textSize)
        Set the label text size
        Parameters:
        type - grid type
        textSize - label text size