Package org.ehcache.config
Interface ResourceUnit
-
- All Known Implementing Classes:
EntryUnit,MemoryUnit
public interface ResourceUnitRepresents a unit in which quantity is expressed in aSizedResourcePool.
-
-
Method Summary
All Methods Instance Methods Abstract Methods Modifier and Type Method Description intcompareTo(long thisSize, long thatSize, ResourceUnit thatUnit)ComparesthisSizein this unit tothatSizeinthatUnit.
-
-
-
Method Detail
-
compareTo
int compareTo(long thisSize, long thatSize, ResourceUnit thatUnit) throws java.lang.IllegalArgumentExceptionComparesthisSizein this unit tothatSizeinthatUnit.Returns 1, 0, or -1 if the
thisSizeofthisis greater than, equal to, or less thanthatSizeofthatUnitrespectively.- Parameters:
thisSize- size in this unitthatSize- size inthatUnitthatUnit- otherResourceUnit- Returns:
- as per the
compareTocontract - Throws:
java.lang.IllegalArgumentException- if the units are not comparable
-
-