本文整理汇总了C#中NHibernate.Engine.QueryParameters.BindParameters方法的典型用法代码示例。如果您正苦于以下问题:C# QueryParameters.BindParameters方法的具体用法?C# QueryParameters.BindParameters怎么用?C# QueryParameters.BindParameters使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类NHibernate.Engine.QueryParameters
的用法示例。
在下文中一共展示了QueryParameters.BindParameters方法的2个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C#代码示例。
示例1: BindParameterValues
/// <summary>
/// Bind all parameter values into the prepared statement in preparation for execution.
/// </summary>
/// <param name="statement">The ADO prepared statement </param>
/// <param name="queryParameters">The encapsulation of the parameter values to be bound. </param>
/// <param name="startIndex">The position from which to start binding parameter values. </param>
/// <param name="session">The originating session. </param>
/// <returns> The number of ADO bind positions actually bound during this method execution. </returns>
protected virtual int BindParameterValues(IDbCommand statement, QueryParameters queryParameters,
int startIndex, ISessionImplementor session)
{
// NH Different behavior:
// The responsibility of parameter binding was entirely moved to QueryParameters
// to deal with positionslParameter+NamedParameter+ParameterOfFilters
return queryParameters.BindParameters(statement, startIndex, session);
}
示例2: BindQueryParameters
protected virtual int BindQueryParameters(IDbCommand command, QueryParameters parameter, int colIndex)
{
colIndex += parameter.BindParameters(command, colIndex, session);
return colIndex;
}