FieldDropdown.Options

public static class FieldDropdown.Options extends Observable<FieldDropdown.OptionsObserver>

The list of all options for a FieldDropdown.

Field Summary

public final List<FieldDropdown.Option> mOptionList

Inherited Field Summary

Public Constructor Summary

FieldDropdown.Options(List<FieldDropdown.Option> options)
Constructs

Public Method Summary

FieldDropdown.Options
clone()
void
copyFrom(FieldDropdown.Options source)
Updates the list of FieldDropdown.Options from source into this instance, and updates all observers.
FieldDropdown.Option
get(int index)
int
getIndexForValue(String value)
Searches options for the first option that matches value.
boolean
int
size()
void
updateOptions(List<FieldDropdown.Option> options)
Replaces the current FieldDropdown.Option list with option, and updates all observers.

Inherited Method Summary

Fields

public final List<FieldDropdown.Option> mOptionList

Public Constructors

public FieldDropdown.Options (List<FieldDropdown.Option> options)

Constructs

Parameters
options The initial options for the new instance.

Public Methods

public FieldDropdown.Options clone ()

Returns

public void copyFrom (FieldDropdown.Options source)

Updates the list of FieldDropdown.Options from source into this instance, and updates all observers.

Parameters
source The FieldDropdown.Options with new of FieldDropdown.Options to use.

public FieldDropdown.Option get (int index)

Parameters
index The index of the FieldDropdown.Option to retrieve.
Returns
  • The

public int getIndexForValue (String value)

Searches options for the first option that matches value.

Parameters
value The value string to match
Returns
  • The index of the first matching value, or -1 if not found.

public boolean isEmpty ()

Returns

public int size ()

Returns

public void updateOptions (List<FieldDropdown.Option> options)

Replaces the current FieldDropdown.Option list with option, and updates all observers.

Parameters
options The new of FieldDropdown.Options to use.