Decision.SetBinding<T> Method (IEnumerable<T>, String, String[])

Solver Foundation 3.0

[This documentation is for preview only, and is subject to change in later releases. Blank topics are included as placeholders.]

Initializes a new instance of the Decision class.

Namespace:  Microsoft.SolverFoundation.Services
Assembly:  Microsoft.Solver.Foundation (in Microsoft.Solver.Foundation.dll)

public void SetBinding<T>(
	IEnumerable<T> binding,
	string valueField,
	params string[] indexFields
)

Type Parameters

T

Parameters

binding
Type: System.Collections.Generic.IEnumerable<T>
A sequence of objects. There is a new binding for each data element.
valueField
Type: System.String
The name of the property of each input object that is assigned the value of the data decisions.
indexFields
Type: System.String[]
The names of the properties of each input object that contains the indexes of the data decisions. There is a new decision for each index set that was provided when the Decision was created.

ExceptionCondition
InvalidModelDataException

A property or field cannot be found, or the property or field is not writeable.

Show: