DynamicPickListRows Class

Contains a list of picklist items in a Lightning component on a Lightning page.

VisualEditor

The following are constructors for DynamicPickListRows.

Creates an instance of the VisualEditor.DynamicPickListRows class using the specified parameters.

public DynamicPickListRows(List<VisualEditor.DataRow> rows, Boolean containsAllRows)

  • rows: Type: List VisualEditor.DataRow List of picklist items.
  • containsAllRows: Type: Boolean Indicates if all values of the picklist are included in a type-ahead search query (true) or only those values initially displayed when the list is clicked on (false). A picklist in a Lightning component can display only the first 200 values of a list. If containsAllRows is set to false, when a user does a type-ahead search to find values in the picklist, the search will only look at those first 200 values that were displayed, not the complete set of picklist values.

Creates an instance of the VisualEditor.DynamicPickListRows class using the specified parameter.

public DynamicPickListRows(List<VisualEditor.DataRow> rows)

Creates an instance of the VisualEditor.DynamicPickListRows class. You can then add rows by using the class’s addRow or addAllRows methods.

public DynamicPickListRows()

The following are methods for DynamicPickListRows.

  • addAllRows(rows)

    Adds a list of picklist items to a dynamic picklist rendered in a Lightning component on a Lightning page.

  • addRow(row)

    Adds a single picklist item to a dynamic picklist rendered in a Lightning component on a Lightning page.

  • clone()

    Makes a duplicate copy of the VisualEditor.DynamicPickListRows object.

  • containsAllRows()

    Returns a Boolean value indicating whether all values of the picklist are included when a user does a type-ahead search query (true) or only those values initially displayed when the list is clicked on (false).

  • get(i)

    Returns a picklist element stored at the specified index.

  • getDataRows()

    Returns a list of picklist items.

  • setContainsAllRows(containsAllRows)

    Sets the value indicating whether all values of the picklist are included when a user does a type-ahead search query (true) or only those values initially displayed when the list is clicked on (false).

  • size()

    Returns the size of the list of VisualEditor.DynamicPickListRows.

  • sort()

    Sorts the list of VisualEditor.DynamicPickListRows.

Adds a list of picklist items to a dynamic picklist rendered in a Lightning component on a Lightning page.

public void addAllRows(List<VisualEditor.DataRow> rows)

Type: void

Adds a single picklist item to a dynamic picklist rendered in a Lightning component on a Lightning page.

public void addRow(VisualEditor.DataRow row)

Type: void

Makes a duplicate copy of the VisualEditor.DynamicPickListRows object.

public Object clone()

Type: Object

Returns a Boolean value indicating whether all values of the picklist are included when a user does a type-ahead search query (true) or only those values initially displayed when the list is clicked on (false).

public Boolean containsAllRows()

Type: Boolean

A picklist in a Lightning component can display only the first 200 values of a list. If containsAllRows is set to false, when a user does a type-ahead search to find values in the picklist, the search will only look at those first 200 values that were displayed, not the complete set of picklist values.

Returns a picklist element stored at the specified index.

public VisualEditor.DataRow get(Integer i)

Type: VisualEditor.DataRow

Returns a list of picklist items.

public List<VisualEditor.DataRow> getDataRows()

Type: List VisualEditor.DataRow

Sets the value indicating whether all values of the picklist are included when a user does a type-ahead search query (true) or only those values initially displayed when the list is clicked on (false).

public void setContainsAllRows(Boolean containsAllRows)

  • containsAllRows: Type: Boolean Indicates if all values of the picklist are included in a type-ahead search query (true) or only those values initially displayed when the list is clicked on (false). A picklist in a Lightning component can display only the first 200 values of a list. If containsAllRows is set to false, when a user does a type-ahead search to find values in the picklist, the search will only look at those first 200 values that were displayed, not the complete set of picklist values.

Type: void

Returns the size of the list of VisualEditor.DynamicPickListRows.

public Integer size()

Type: Integer

Sorts the list of VisualEditor.DynamicPickListRows.

public void sort()

Type: void