LabKit MATLAB Workbench

reference

FrameworkApp SDK API

labkit.app.event.ListSelection

Describe selected file or list item identities.

Syntax

selection = labkit.app.event.ListSelection(Name=Value)

Description

ListSelection carries stable item IDs, positive display indices, or both for file panels and list controls. When both are supplied they have equal lengths and matching order.

Optional Name-Value Arguments

Ids
Unique row string or cellstr array. Default: empty.
Indices
Unique positive integer numeric row. Default: empty.

Outputs

selection
Immutable labkit.app.event.ListSelection value.

Errors

labkit:app:contract:UnknownArgument
An option is unknown, duplicated, or unpaired.
labkit:app:contract:InvalidValue
IDs or indices are malformed or have inconsistent lengths.

Example

selection = labkit.app.event.ListSelection( ...
Ids=["sample-a", "sample-b"], Indices=[1 3]);
assert(isequal(selection.Indices, [1 3]))

Source

This page is generated from the MATLAB help text in +labkit/+app/+event/ListSelection.m.