Skip to content

Commit b027f4f

Browse files
Fix comments.
1 parent ca5c931 commit b027f4f

File tree

1 file changed

+6
-8
lines changed

1 file changed

+6
-8
lines changed

LazyProxy.Autofac/AutofacExtensions.cs

Lines changed: 6 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -13,8 +13,8 @@ namespace LazyProxy.Autofac
1313
public static class AutofacExtensions
1414
{
1515
/// <summary>
16-
/// Is used to register non open generic interface TFrom to class TTo by creation a lazy proxy at runtime.
17-
/// The real class To will be instantiated only after first method or property execution.
16+
/// Registers a mapping of a non-open generic interface TFrom to the class TTo via run-time generated lazy
17+
/// proxy type. The real class TTo will be instantiated only after first method or property execution.
1818
/// </summary>
1919
/// <param name="builder">The instance of the Autofac container builder.</param>
2020
/// <param name="name">The registration name. Null if named registration is not required.</param>
@@ -29,8 +29,8 @@ public static IRegistrationBuilder<object, SimpleActivatorData, SingleRegistrati
2929
builder.RegisterLazy(typeof(TFrom), typeof(TTo), name, nonLazyRegistrationMutator);
3030

3131
/// <summary>
32-
/// Is used to register non open generic interface TFrom to class TTo by creation a lazy proxy at runtime.
33-
/// The real class To will be instantiated only after first method or property execution.
32+
/// Registers a mapping of a non-open generic interface TFrom to the class TTo via run-time generated lazy
33+
/// proxy type. The real class TTo will be instantiated only after first method or property execution.
3434
/// </summary>
3535
/// <param name="typeFrom">The linked interface.</param>
3636
/// <param name="typeTo">The linked class.</param>
@@ -42,7 +42,6 @@ public static IRegistrationBuilder<object, SimpleActivatorData, SingleRegistrati
4242
RegisterLazy(this ContainerBuilder builder, Type typeFrom, Type typeTo, string name = null,
4343
IRegistrationMutator nonLazyRegistrationMutator = null)
4444
{
45-
// There is no way to constraint it on the compilation step.
4645
if (!typeFrom.IsInterface)
4746
{
4847
throw new NotSupportedException(
@@ -68,8 +67,8 @@ public static IRegistrationBuilder<object, SimpleActivatorData, SingleRegistrati
6867
}
6968

7069
/// <summary>
71-
/// Is used to register open generic interface TFrom to class TTo by creation a lazy proxy at runtime.
72-
/// The real class To will be instantiated only after first method or property execution.
70+
/// Registers a mapping of an open generic interface TFrom to the class TTo via run-time generated lazy
71+
/// proxy type. The real class TTo will be instantiated only after first method or property execution.
7372
/// </summary>
7473
/// <param name="typeFrom">The linked interface.</param>
7574
/// <param name="typeTo">The linked class.</param>
@@ -81,7 +80,6 @@ public static IRegistrationBuilder<object, OpenGenericDelegateActivatorData, Dyn
8180
RegisterGenericLazy(this ContainerBuilder builder, Type typeFrom, Type typeTo, string name = null,
8281
IRegistrationMutator nonLazyRegistrationMutator = null)
8382
{
84-
// There is no way to constraint it on the compilation step.
8583
if (!typeFrom.IsInterface)
8684
{
8785
throw new NotSupportedException(

0 commit comments

Comments
 (0)