Skip to main content
Version: 8.1

Vision - List Scripting Functions

This page details the various component and extension functions available for Vision's List component.

Component Functions​

.addSelectionInterval(start, end)​

  • Description
    • Adds the options at indexes start through end (inclusive) to the selected options.
  • Parameters
    • int start - The first index (stating at 0) to add to the selection.
    • int end - The last index (stating at 0) to add to the selection.
  • Return
    • None

.clearSelection()​

  • Description
    • Clears the current selection, making nothing selected.
  • Parameters
    • None
  • Return
    • None

.getSelectedIndices()​

  • Description
    • Returns a list of the selected indices in increasing order. Returns an empty list if nothing is selected.
  • Parameters
    • None
  • Return
    • List of Integers

.getSelectedValue()​

  • Description
    • Returns the currently selected value, or None if the selection is empty.
  • Parameters
    • None
  • Return
    • Object

.getSelectedValues()​

  • Description
    • Returns a list of the currently selected values. Returns an empty list if the selection is empty.
  • Parameters
    • None
  • Return
    • Object[]

.isSelectedIndex(index)​

  • Description
    • Checks whether or not the given index is currently selected.
  • Parameters
    • int index
  • Return
    • boolean

.isSelectionEmpty()​

  • Description
    • Checks to see if anything is selected in the list or not.
  • Parameters
    • None
  • Return
    • boolean

.setSelectedValue(value)​

  • Description
    • Sets the currently selected value to the argument, if found in the list.
  • Parameters
    • Object value
  • Return
    • None

.setSelectedValues(valueList)​

New in 8.1.0
  • Description

    • Sets the currently selected values in the component, selecting multiple options. The options selected are determined by the valueList parameter, which is expected to be a list of literal values that map to options in the list.
  • Parameters

    • Object valueList - Python list containing values that should map to options in the component.
  • Return

    • None

Extension Functions​

This component does not have extension functions associated with it.