Interface ICustomProperty
- All Known Implementing Classes:
CustomProperty
public interface ICustomProperty
Represents a custom property on a map element.
Method Summary
Modifier and Type Method Description boolean
equals(java.lang.Object anObject)
Tests for equality between two custom properties.boolean
getAsBool()
byte
getAsByte()
char
getAsChar()
java.awt.Color
getAsColor()
double
getAsDouble()
<T extends java.lang.Enum<T>>
TgetAsEnum(java.lang.Class<T> enumType)
java.net.URL
getAsFile()
float
getAsFloat()
int
getAsInt()
long
getAsLong()
short
getAsShort()
java.lang.String
getAsString()
java.lang.String
getType()
int
hashCode()
Returns the hash code for this custom property.void
setType(java.lang.String type)
void
setValue(boolean value)
void
setValue(char value)
void
setValue(double value)
void
setValue(long value)
void
setValue(java.awt.Color value)
void
setValue(java.lang.Enum<?> value)
void
setValue(java.lang.String value)
void
setValue(java.net.URL value)
Method Details
setValue
void setValue(java.net.URL value)setValue
void setValue(java.lang.String value)setValue
void setValue(char value)setValue
void setValue(java.lang.Enum<?> value)setValue
void setValue(long value)setValue
void setValue(double value)setValue
void setValue(boolean value)setValue
void setValue(java.awt.Color value)getAsString
java.lang.String getAsString()getAsChar
char getAsChar()getAsBool
boolean getAsBool()getAsColor
java.awt.Color getAsColor()getAsFloat
float getAsFloat()getAsDouble
double getAsDouble()getAsByte
byte getAsByte()getAsShort
short getAsShort()getAsInt
int getAsInt()getAsLong
long getAsLong()getAsEnum
<T extends java.lang.Enum<T>> T getAsEnum(java.lang.Class<T> enumType)getAsFile
java.net.URL getAsFile()getType
java.lang.String getType()setType
void setType(java.lang.String type)equals
boolean equals(java.lang.Object anObject)Tests for equality between two custom properties. Two custom properties are equal if they both have the same type and string value.- Overrides:
equals
in classjava.lang.Object
- Parameters:
anObject
- The custom property to test equality for- Returns:
- Whether the two custom properties are equal, or false
if
anObject
is not a custom property
hashCode
int hashCode()Returns the hash code for this custom property. The hash code for a custom property is equal to its type's hash code times 31 plus its value's hash code.- Overrides:
hashCode
in classjava.lang.Object
- Returns:
- The hash code for this custom property