NodePickerModel
Class in Oadm.Sdk.Client.Controls · Oadm.Sdk.Client.dll
What a NodePicker shows (its data context): open or closed, where on the canvas, the search and the rows. NodePickerModel.Show opens it with the kinds to offer, grouped in their order; a search narrows them by name. The picker calls NodePickerModel.Choose for a click or Enter, the canvas’s view model adds the node in NodePickerModel.Chosen. Vision Center’s pipeline editor and Provisioning’s profile editor.
public class NodePickerModel : ObservableObjectInherits ObservableObject
Properties
Section titled “Properties”Entries
Section titled “Entries”RangeObservableCollection<NodePickerEntry> Entries { get; }The rows the list shows now: each group’s heading, then its kinds.
IsEmpty
Section titled “IsEmpty”bool IsEmpty { get; private set; }No kind matches the search.
IsOpen
Section titled “IsOpen”bool IsOpen { get; private set; }The list shows.
double Left { get; private set; }The left edge of the list on the canvas (pixels of the canvas control).
SearchText
Section titled “SearchText”string SearchText { get; set; }The search; the list shows the kinds whose name contains it.
ShownItems
Section titled “ShownItems”IReadOnlyList<NodePickerItem> ShownItems { get; }The kinds the list shows now, in order.
double Top { get; private set; }The top edge of the list on the canvas (pixels of the canvas control).
Methods
Section titled “Methods”Choose
Section titled “Choose”void Choose(NodePickerItem item)Closes the list and raises NodePickerModel.Chosen with item.
virtual void Close()Closes the list.
void Show(IEnumerable<NodePickerItem> items, double left, double top)Opens the list at (left, top) with items, grouped by their NodePickerItem.Group in the order they come; the search starts empty.
Events
Section titled “Events”Chosen
Section titled “Chosen”event EventHandler<NodePickerItem>? ChosenA kind was chosen (a click or Enter in the search); the list is closed before.