com.esri.arcgis.display
Interface IColorRamp

All Superinterfaces:
Serializable
All Known Subinterfaces:
IAlgorithmicColorRamp, IMultiPartColorRamp, IPresetColorRamp, IRandomColorRamp
All Known Implementing Classes:
AlgorithmicColorRamp, MultiPartColorRamp, PresetColorRamp, RandomColorRamp

public interface IColorRamp
extends Serializable

Provides access to the methods and properties common to all color ramp objects.

Description

IColorRamp maintains information about the way equal steps are derived between two or more colors, or how to randomly or sequentially derived colors from a list of predefined colors, or from the color gamut. The IColorRamp interface provides the basic functions for all color ramps in ArcMap.

Product Availability

Available with ArcGIS Engine, ArcGIS Desktop, and ArcGIS Server.

Supported Platforms

Windows, Solaris, Linux

See Also:
IPresetColorRamp, IMultiPartColorRamp, IAlgorithmicColorRamp, IColorRamp.getColor(int), IRandomColorRamp, IColorRamp.createRamp(boolean[]), IColorRamp

Method Summary
 void createRamp(boolean[] ok)
          Generates a color ramp with length determined by Size value.
 IColor getColor(int index)
          The color at the given index position.
 IEnumColors getColors()
          The list of colors.
 String getName()
          The name of the color ramp.
 int getSize()
          The number of colors that will be generated by the CreateRamp method.
 void setName(String pName)
          The name of the color ramp.
 void setSize(int count)
          The number of colors that will be generated by the CreateRamp method.
 

Method Detail

setName

void setName(String pName)
             throws IOException,
                    AutomationException
The name of the color ramp.

Description

Name is the name of an instance of a color ramp.

Product Availability

Available with ArcGIS Engine, ArcGIS Desktop, and ArcGIS Server.

Supported Platforms

Windows, Solaris, Linux

Parameters:
pName - The pName (in)
Throws:
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.

getName

String getName()
               throws IOException,
                      AutomationException
The name of the color ramp.

Description

Name is the name of an instance of a color ramp.

Product Availability

Available with ArcGIS Engine, ArcGIS Desktop, and ArcGIS Server.

Supported Platforms

Windows, Solaris, Linux

Returns:
The pName
Throws:
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.

setSize

void setSize(int count)
             throws IOException,
                    AutomationException
The number of colors that will be generated by the CreateRamp method.

Description

Size is the number of colors that will be generated when the CreateRamp method is used.

Product Availability

Available with ArcGIS Engine, ArcGIS Desktop, and ArcGIS Server.

Supported Platforms

Windows, Solaris, Linux

Parameters:
count - The count (in)
Throws:
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.

getSize

int getSize()
            throws IOException,
                   AutomationException
The number of colors that will be generated by the CreateRamp method.

Description

Size is the number of colors that will be generated when the CreateRamp method is used.

Product Availability

Available with ArcGIS Engine, ArcGIS Desktop, and ArcGIS Server.

Supported Platforms

Windows, Solaris, Linux

Returns:
The count
Throws:
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.

getColors

IEnumColors getColors()
                      throws IOException,
                             AutomationException
The list of colors. Call CreateRamp before calling this method.

Description

Colors is how you can populate an IEnumColors object in order to easily retrieve the colors in a color ramp.

Product Availability

Available with ArcGIS Engine, ArcGIS Desktop, and ArcGIS Server.

Supported Platforms

Windows, Solaris, Linux

Returns:
A reference to a com.esri.arcgis.display.IEnumColors
Throws:
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.

getColor

IColor getColor(int index)
                throws IOException,
                       AutomationException
The color at the given index position. Call CreateRamp before calling this method.

Product Availability

Available with ArcGIS Engine, ArcGIS Desktop, and ArcGIS Server.

Parameters:
index - The index (in)
Returns:
A reference to a com.esri.arcgis.display.IColor
Throws:
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.

createRamp

void createRamp(boolean[] ok)
                throws IOException,
                       AutomationException
Generates a color ramp with length determined by Size value.

Description

CreateRamp generates the number of colors in a color ramp as specified in the Size property. The boolean pOK is a mask, i.e., you supply the boolean object and the method will set its value. Generally speaking pOK will only return false if a property is missing.

Remarks

Use the CreateRamp after you have set the other properties like Size and the colors specific paramters.

Product Availability

Available with ArcGIS Engine, ArcGIS Desktop, and ArcGIS Server.

Supported Platforms

Windows, Solaris, Linux

Parameters:
ok - The ok (out: use single element array)
Throws:
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.
See Also:
IPresetColorRamp, IMultiPartColorRamp, IAlgorithmicColorRamp, IColorRamp.getColor(int), IRandomColorRamp, IColorRamp.createRamp(boolean[]), IColorRamp