Skip to content

Commit

Permalink
Fix docs
Browse files Browse the repository at this point in the history
  • Loading branch information
Oren Novotny committed Nov 24, 2015
1 parent 248032e commit 99ad272
Showing 1 changed file with 13 additions and 1 deletion.
14 changes: 13 additions & 1 deletion src/Ninject/Planning/Bindings/BindingConfigurationBuilder.cs
Original file line number Diff line number Diff line change
Expand Up @@ -525,6 +525,12 @@ public IBindingWithOrOnSyntax<T> WithConstructorArgument(Type type, Func<IContex
return this.WithConstructorArgument(type, (context, target) => callback(context));
}

/// <summary>
/// Indicates that the specified constructor argument should be overridden with the specified value.
/// </summary>
/// <typeparam name="TValue">Specifies the argument type to override.</typeparam>
/// <param name="callback">The callback to invoke to get the value for the argument.</param>
/// <returns>The fluent syntax.</returns>
public IBindingWithOrOnSyntax<T> WithConstructorArgument<TValue>(Func<IContext, TValue> callback)
{
return this.WithConstructorArgument(typeof(TValue), (context, target) => callback(context));
Expand All @@ -542,6 +548,12 @@ public IBindingWithOrOnSyntax<T> WithConstructorArgument(Type type, Func<IContex
return this;
}

/// <summary>
/// Indicates that the specified constructor argument should be overridden with the specified value.
/// </summary>
/// <typeparam name="TValue">Specifies the argument type to override.</typeparam>
/// <param name="callback">The callback to invoke to get the value for the argument.</param>
/// <returns>The fluent syntax.</returns>
public IBindingWithOrOnSyntax<T> WithConstructorArgument<TValue>(Func<IContext, ITarget, TValue> callback)
{
this.WithConstructorArgument(typeof (TValue), callback);
Expand Down Expand Up @@ -708,4 +720,4 @@ private static bool DoesAnyAncestorMatch(IRequest request, Predicate<IContext> p
DoesAnyAncestorMatch(parentContext.Request, predicate);
}
}
}
}

0 comments on commit 99ad272

Please sign in to comment.