metagloss 0.0.2

net.sf.metagloss.preference
Annotation Type FloatConstraint


@Target(value={TYPE,FIELD})
@Retention(value=RUNTIME)
@Inherited
public @interface FloatConstraint

Annotation type to set the valid numerical range for an EditTextPreference.

Must be used in conjunction with BindPreference.

Example

@FloatConstraint(min = 1.0, max = 5.0)
@BindPreference(format="Updates every %s hours")
public static final String PREF_PROJECT_UPDATE_INTERVAL = "update_interval";


Optional Element Summary
 java.lang.String key
          The key value associated with a preference.
 float max
           
 float min
           
 

key

public abstract java.lang.String key
The key value associated with a preference.

Returns:
Preference element's key value.
See Also:
Preference.getKey()
Default:
""

min

public abstract float min
Default:
0.0f

max

public abstract float max
Default:
1.0f