sos.dated.util
Interface DatedMap.Entry

Enclosing interface:
DatedMap

public static interface DatedMap.Entry

An entry in a dated map. This interface is an adaptation of the interface java.util.Map.Entry. The only difference is that the setValue method has been enhanced to take a date range.

Since:
1.0

Method Summary
 boolean equals(java.lang.Object object)
          Indicates if this entry is equivalent to the specified object.
 java.lang.Object getKey()
          Returns this entry's key.
 java.lang.Object getValue()
          Returns this entry's value.
 int hashCode()
          Returns a hash code value for this entry.
 java.lang.Object setValue(java.lang.Object value, java.util.Date from, java.util.Date to)
          Sets the value to be associated with the key in the specified date range.
 

Method Detail

equals

public boolean equals(java.lang.Object object)
Indicates if this entry is equivalent to the specified object.

Overrides:
equals in class java.lang.Object
Parameters:
object -
Returns:
true if this entry is equal to the specified object

getKey

public java.lang.Object getKey()
Returns this entry's key.

Returns:
the key

getValue

public java.lang.Object getValue()
Returns this entry's value.

Returns:
the value associated with the key

hashCode

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

Overrides:
hashCode in class java.lang.Object
Returns:
a hash code value for this entry.

setValue

public java.lang.Object setValue(java.lang.Object value,
                                 java.util.Date from,
                                 java.util.Date to)
Sets the value to be associated with the key in the specified date range.

Parameters:
value -
from - start of date range (inclusive) to map to value
to - end of date range (exclusive) to map to value
Returns:
the object previously mapped to this entry's key in the specified date range
Throws:
DateOutOfRangeException - if the specified range does not include the date at which this entry is being viewed or if the underlying map is not static throughout the specified range


Copyright 2003 Side of Software (SOS). All rights reserved.