Parameter.SetBinding<T> Method (IEnumerable<T>, String, Rational, String)
[This documentation is for preview only, and is subject to change in later releases. Blank topics are included as placeholders.]
Binds the parameter to data.
Assembly: Microsoft.Solver.Foundation (in Microsoft.Solver.Foundation.dll)
public void SetBinding<T>( IEnumerable<T> binding, string valueField, Rational defaultValue, params string indexFields )
- Type: System.Collections.Generic.IEnumerable<>
A sequence of objects, one for each data element.
- Type: System.String
The name of the property of each input object that contains the value of the data element.
- Type: Microsoft.SolverFoundation.Common.Rational
The default value for indexes that are not provided by the binding.
Each parameter must be bound before solving. The data must be in the form of a sequence of objects, where each object has properties for the value and index(es) of the data element.
The data is read each time Solve() is called.
- Full trust for the immediate caller. This member cannot be used by partially trusted code. For more information, see Using Libraries from Partially Trusted Code.