com.esri.aims.mtier.model.map.layer.renderer.symbol
Class HashLineSymbol

java.lang.Object
  extended by com.esri.aims.mtier.model.map.layer.renderer.symbol.Symbol
      extended by com.esri.aims.mtier.model.map.layer.renderer.symbol.HashLineSymbol
All Implemented Interfaces:
Serializable

public class HashLineSymbol
extends Symbol

This is a Line object used for drawing railroad symbols. The HashLineSymbol extends the Symbol object.

See Also:
Serialized Form

Field Summary
static String BACKGROUND
           
static String FOREGROUND
           
 
Constructor Summary
HashLineSymbol()
          Constructs an instance of a HashLineSymbol.
 
Method Summary
 String getColor()
          Returns the HashLineSymbol's color value.
 String getHashType()
          Returns the HashLineSymbol's type value.
 long getInterval()
          Returns the distance between railroad cross hashes in pixels.
 long getLineThickness()
          Returns the HashLineSymbol's line thickness as pixels.
 long getTickThickness()
          Returns the HashLineSymbol's tick thickness as pixels.
 double getTransparency()
          Returns the HashLineSymbol's transparency value.
 String getType()
          Returns the type of symbol, "HashLine".
 long getWidth()
          Returns the width of the crosshash in pixels.
 boolean isAntialiasing()
          Returns true, if the HashLineSymbol's antialiasing value is true.
 boolean isOverlap()
          Determines if the HashLineSymbol's overlap value is set.
 void setAntialiasing(boolean value)
          Sets the HashLineSymbol's antialiasing value.
 void setColor(String value)
          Sets the HashLineSymbol's color value.
 void setHashType(String value)
          Sets the HashLineSymbol's type value.
 void setInterval(long value)
          Sets the distance between railroad crosshashes in pixels.
 void setLineThickness(long value)
          Sets the HashLineSymbol's line thickness in pixels.
 void setOverlap(boolean value)
          Sets the overlap value, which determines if labels can overlap this symbol.
 void setTickThickness(long value)
          Sets the HashLineSymbol's tick thickness in pixels.
 void setTransparency(double value)
          Sets the HashLineSymbol's transparency value.
 void setWidth(long value)
          Sets the width of the crosshash in pixels.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

FOREGROUND

public static final String FOREGROUND
See Also:
Constant Field Values

BACKGROUND

public static final String BACKGROUND
See Also:
Constant Field Values
Constructor Detail

HashLineSymbol

public HashLineSymbol()
Constructs an instance of a HashLineSymbol. Example:
HashLineSymbol hashLine = new HashLineSymbol();

Method Detail

getType

public String getType()
Returns the type of symbol, "HashLine".

Specified by:
getType in class Symbol
Returns:
String

setTransparency

public void setTransparency(double value)
Sets the HashLineSymbol's transparency value. Example:
 hashline.setTransparency(1.0);
 

Parameters:
value - the transparency value.
See Also:
getTransparency()

getTransparency

public double getTransparency()
Returns the HashLineSymbol's transparency value. Example:
 double transparency = hashLine.getTransparency();
 

Returns:
double
See Also:
setTransparency(double)

setAntialiasing

public void setAntialiasing(boolean value)
Sets the HashLineSymbol's antialiasing value. Note that the time to generate a map may significantly increase when this property is set to True. Example:
 hashLine.setAntialiasing(true);
 

Parameters:
value - the antialiasing value that is used to make edges of labels and symbols smoother. When set to True, antialiasing is active.
See Also:
isAntialiasing()

isAntialiasing

public boolean isAntialiasing()
Returns true, if the HashLineSymbol's antialiasing value is true. Example:
 if(hashLine.isAntialiasing() == true){
  hashLine.setAntialiasing(false);
 }
 

Returns:
boolean
See Also:
setAntialiasing(boolean)

setColor

public void setColor(String value)
Sets the HashLineSymbol's color value. Example:
 hashLine.setColor("255,255,255");
 

Parameters:
value - the color value.
See Also:
getColor()

getColor

public String getColor()
Returns the HashLineSymbol's color value. Example:
 String color = hashLine.getColor();
 

Returns:
String
See Also:
setColor(java.lang.String)

setHashType

public void setHashType(String value)
Sets the HashLineSymbol's type value. If type is foreground, the symbol draws a railroad with a crosshash. If type is background, the symbol draws as a simple line without the crosshash. Example:
 hashLine.setHashType(hashLine.BACKGROUND);
 

Parameters:
value - the type value - foreground or background.
See Also:
getHashType()

getHashType

public String getHashType()
Returns the HashLineSymbol's type value. Example:
 String hashType = hashLine.getHashType();
 

Returns:
String
See Also:
setHashType(java.lang.String)

setWidth

public void setWidth(long value)
Sets the width of the crosshash in pixels. Example:
 hashLine.setWidth(10);
 

Parameters:
value - the width value.
See Also:
getWidth()

getWidth

public long getWidth()
Returns the width of the crosshash in pixels. Example:
 long width = hashLine.getWidth();
 

Returns:
long
See Also:
setWidth(long)

setInterval

public void setInterval(long value)
Sets the distance between railroad crosshashes in pixels. Example:
 hashLine.setInterval(2);
 

Parameters:
value - the interval value.
See Also:
getInterval()

getInterval

public long getInterval()
Returns the distance between railroad cross hashes in pixels. Example:
 long interval = hashLine.getInterval();
 

Returns:
long

setLineThickness

public void setLineThickness(long value)
Sets the HashLineSymbol's line thickness in pixels. Example:
 hashLine.setLineThickness(2);
 

Parameters:
value - the line thickness value.
See Also:
getLineThickness()

getLineThickness

public long getLineThickness()
Returns the HashLineSymbol's line thickness as pixels.

 long lineThickness = hashLine.getLineThickness();
 

Returns:
long
See Also:
setLineThickness(long)

setTickThickness

public void setTickThickness(long value)
Sets the HashLineSymbol's tick thickness in pixels.

 hashLine.setTickThickness(25);
 

Parameters:
value - the tick thickness value.
See Also:
getTickThickness()

getTickThickness

public long getTickThickness()
Returns the HashLineSymbol's tick thickness as pixels.

 long tickThickness = hashLine.getTickThickness();
 

Returns:
long
See Also:
getTickThickness()

setOverlap

public void setOverlap(boolean value)
Sets the overlap value, which determines if labels can overlap this symbol. When True, labels can overlap. If labels are not drawing as expected, check if overlap is set to False for this symbol or for any other symbol in this service.

 hashLine.setOverlap(true);
 

Parameters:
value - the overlap value.
See Also:
isOverlap()

isOverlap

public boolean isOverlap()
Determines if the HashLineSymbol's overlap value is set.

 if(hashLine.isOverlap() == true){
  hashLine.setOverlap(false);
 }
 

Returns:
boolean
See Also:
setOverlap(boolean)