com.mapquest
Class DisplayState

java.lang.Object
  extended bycom.mapquest.MQObject
      extended bycom.mapquest.DisplayState
All Implemented Interfaces:
java.lang.Cloneable

public class DisplayState
extends MQObject

Defines the Map Drawing State. It includes such information as the content type and the DPI. By default, maps are generated using content type = image/gif and 72 DPI.

See Also:
ContentType

Field Summary
static int CLASS_ID
           
static java.lang.String CLASS_NAME
           
 
Fields inherited from class com.mapquest.MQObject
DEFAULT_ID, DEFAULT_NAME, DEFAULT_VERSION, FORMAT_NUMERIC_ID, FORMAT_TEXT_NAME, INVALID_ID, INVALID_NAME, INVALID_VERSION
 
Constructor Summary
DisplayState()
          Default constructor.
 
Method Summary
 boolean equals(java.lang.Object otherObject)
          Compares this object to the specified object.
 boolean getAntiAlias()
          Gets the anti-alias flag
 int getClassId()
          Returns the numeric id of this class.
 java.lang.String getClassName()
          Returns the text name of this class.
 ContentType getContentType()
          Returns the Mapquest content Type for the map output.
 long getDPI()
          Returns the DPI for the map output.
 int hashCode()
          Returns a hash code for this DisplayState.
 void init()
          Initializes object.
 void setAntiAlias(boolean bAA)
          Sets anti-alias flag, for use with PNG and GIF default is on or true
 void setContentType(ContentType contenttype)
          Sets the content Type for the map output.
 void setDPI(long DPI)
          Sets the DPI for the map output.
 
Methods inherited from class com.mapquest.MQObject
clone, getFormat, getIdWithVersion, getNameWithVersion, getObjectVersion, getTypeId, getTypeName, getVerboseConsoleOutput, setFormat, setObjectVersion, setVerboseConsoleOutput, toString
 
Methods inherited from class java.lang.Object
getClass, notify, notifyAll, wait, wait, wait
 

Field Detail

CLASS_ID

public static final int CLASS_ID
See Also:
Constant Field Values

CLASS_NAME

public static final java.lang.String CLASS_NAME
See Also:
Constant Field Values
Constructor Detail

DisplayState

public DisplayState()
Default constructor.

Method Detail

init

public void init()
Initializes object.

Overrides:
init in class MQObject

getClassId

public int getClassId()
Returns the numeric id of this class.

Overrides:
getClassId in class MQObject
Returns:
the numeric id of this class.

getClassName

public java.lang.String getClassName()
Returns the text name of this class.

Overrides:
getClassName in class MQObject
Returns:
the text name of this class.

setContentType

public void setContentType(ContentType contenttype)
Sets the content Type for the map output.

Parameters:
contenttype - The content type, default is "image/gif"

getContentType

public ContentType getContentType()
Returns the Mapquest content Type for the map output.

Returns:
The content type with this DisplayState object.

setDPI

public void setDPI(long DPI)
Sets the DPI for the map output.

Parameters:
DPI - The DPI, default is 72.

getDPI

public long getDPI()
Returns the DPI for the map output.

Returns:
The DPI of this DisplayState object.

setAntiAlias

public void setAntiAlias(boolean bAA)
Sets anti-alias flag, for use with PNG and GIF default is on or true

Parameters:
bAA - the anti-alias flag

getAntiAlias

public boolean getAntiAlias()
Gets the anti-alias flag

Returns:
bAA the anti-alias flag

equals

public boolean equals(java.lang.Object otherObject)
Compares this object to the specified object. The result is true if and only if the argument is not null and is a DisplayState object that has same attributes as this object.

Overrides:
equals in class MQObject
Parameters:
otherObject - the object to compare this DisplayState against.
Returns:
true if the DisplayState objects are equal; false otherwise.

hashCode

public int hashCode()
Returns a hash code for this DisplayState.

Overrides:
hashCode in class MQObject
Returns:
a hash code value for this DisplayState.