Class RenderingRule


  • public final class RenderingRule
    extends Object
    Represents the rule for how an ImageServiceRaster should be rendered or processed.

    A rendering rule defines the processing that is to be done to an ImageServiceRaster on the ArcGIS image service. An instance of this class can be created from a RenderingRuleInfo or a JSON string that specifies a service-defined or client-defined rendering rule. A list of raster functions and the syntax for rendering rules can be found at ArcGIS REST API documentation.

    Since:
    100.1.0
    • Constructor Detail

      • RenderingRule

        public RenderingRule​(RenderingRuleInfo renderingRuleInfo)
        Creates a RenderingRule from a rendering rule info.
        Parameters:
        renderingRuleInfo - info to create this rendering rule
        Throws:
        IllegalArgumentException - if renderingRuleInfo is null
        Since:
        100.1.0
      • RenderingRule

        public RenderingRule​(String renderingRuleJson)
        Creates a RenderingRule from a rendering rule JSON string.
        Parameters:
        renderingRuleJson - the JSON that could either be a raster function object used in the image service REST API or a predefined service rendering rule
        Throws:
        IllegalArgumentException - if renderingRuleJson is null or empty
        Since:
        100.1.0
    • Method Detail

      • getRenderingRuleInfo

        public RenderingRuleInfo getRenderingRuleInfo()
        Gets the rendering rule info.
        Returns:
        the rendering rule info
        Since:
        100.1.0
      • getRenderingRuleJson

        public String getRenderingRuleJson()
        Gets the JSON used to create this rendering rule.
        Returns:
        the JSON used to create this rendering rule
        Since:
        100.1.0