com.esri.core.symbol
Class FillSymbol

java.lang.Object
  extended by com.esri.core.symbol.FillSymbol
All Implemented Interfaces:
Symbol, Serializable
Direct Known Subclasses:
SimpleFillSymbol

public abstract class FillSymbol
extends Object
implements Symbol

Base class for polygon symbols. Use the subclass, SimpleFillSymbol, to draw polygon features on the graphics layer. The fill symbol can have an optional outline, which is defined by a line symbol.

See Also:
Serialized Form

Constructor Summary
FillSymbol()
          Instantiates an empty object of FillSymbol.
FillSymbol(org.codehaus.jackson.JsonNode node)
          Instantiates an object of FillSymbol from a JsonNode.
 
Method Summary
 boolean equals(Object obj)
           
 int getAlpha()
          Helper to getColor() that just returns the color's alpha value.
 int getColor()
          Returns the color to fill the polygon with.
 LineSymbol getOutline()
          Returns the outline of the polygon.
 int hashCode()
           
 void setAlpha(int alpha)
          Sets the symbol transparency.
 void setColor(int color)
          Sets the color to fill the polygon with.
 void setOutline(LineSymbol outline)
          Sets the outline of the polygon.
 
Methods inherited from class java.lang.Object
getClass, notify, notifyAll, toString, wait, wait, wait
 
Methods inherited from interface com.esri.core.symbol.Symbol
copy, toJson
 

Constructor Detail

FillSymbol

public FillSymbol(org.codehaus.jackson.JsonNode node)
           throws Exception
Instantiates an object of FillSymbol from a JsonNode.

Parameters:
node - the FillSymbol node.
Throws:
Exception

FillSymbol

public FillSymbol()
Instantiates an empty object of FillSymbol.

Method Detail

getColor

public int getColor()
Returns the color to fill the polygon with. The color is a 32bit value containing alpha as well as RGB. This 32bit value is not pre-multiplied, meaning that its alpha can be any value, regardless of the values of RGB. See the Color class for more details.

Returns:
the color in RGB color value.

setColor

public void setColor(int color)
Sets the color to fill the polygon with. The color is a 32bit value containing alpha as well as RGB. This 32bit value is not pre-multiplied, meaning that its alpha can be any value, regardless of the values of RGB. See the Color class for more details.

Parameters:
color - the color in RGB color value.

getAlpha

public int getAlpha()
Helper to getColor() that just returns the color's alpha value. This is the same as calling getColor() >>> 24. It always returns a value between 0 (completely transparent) and 255 (completely opaque).

Returns:
the alpha component of the symbol's color.

setAlpha

public void setAlpha(int alpha)
Sets the symbol transparency.

Parameters:
alpha - the alpha component of the symbol's color.
See Also:
getAlpha()

getOutline

public LineSymbol getOutline()
Returns the outline of the polygon.

Returns:
the outline of the polygon.

setOutline

public void setOutline(LineSymbol outline)
Sets the outline of the polygon.

Parameters:
outline - the outline symbol.

hashCode

public int hashCode()
Overrides:
hashCode in class Object

equals

public boolean equals(Object obj)
Overrides:
equals in class Object


Copyright © 2012. All Rights Reserved.