-
- All Implemented Interfaces:
-
org.readium.r2.navigator.preferences.Preference
public interface RangePreference<T extends Comparable<T>> implements Preference<T>
A Preference whose values must be in a ClosedRange of T.
-
-
Method Summary
Modifier and Type Method Description abstract Unitincrement()Increment the preference value from its current value or a default value. abstract Unitdecrement()Decrement the preference value from its current value or a default value. abstract StringformatValue(T value)Format value in a way suitable for display, including unit if relevant. abstract ClosedRange<T>getSupportedRange()abstract TgetValue()The current value of the preference. abstract TgetEffectiveValue()The value that will be effectively used by the navigator if preferences are submitted as they are. abstract BooleangetIsEffective()If this preference will be effectively used by the navigator if preferences are submitted as they are. -
-
Method Detail
-
increment
abstract Unit increment()
Increment the preference value from its current value or a default value.
-
decrement
abstract Unit decrement()
Decrement the preference value from its current value or a default value.
-
formatValue
abstract String formatValue(T value)
Format value in a way suitable for display, including unit if relevant.
-
getSupportedRange
abstract ClosedRange<T> getSupportedRange()
-
getEffectiveValue
abstract T getEffectiveValue()
The value that will be effectively used by the navigator if preferences are submitted as they are.
-
getIsEffective
abstract Boolean getIsEffective()
If this preference will be effectively used by the navigator if preferences are submitted as they are.
-
-
-
-