Skip to content

Commit

Permalink
Remove Build, BeforeBuild and AfterBuild method from II18NServiceColl…
Browse files Browse the repository at this point in the history
…ection interface.
  • Loading branch information
alexinea committed Jan 10, 2020
1 parent abecd98 commit ee7db2c
Show file tree
Hide file tree
Showing 2 changed files with 1 addition and 21 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -32,10 +32,8 @@ internal static void AllDone(II18NServiceCollection services) {
s.AddSingleton(provider => new TranslationProcessor(provider.GetServices<ITranslatePackage>().ToDictionary(package => package.PackageKey.GetHashCode())));
});


SetResolver(serviceImpl.Build());
}

SetResolver(services.Build());
}

public static IServiceProvider GetServiceResolver() => ServiceResolver ?? throw new NullReferenceException(nameof(ServiceResolver));
Expand Down
18 changes: 0 additions & 18 deletions src/Cosmos.I18N/Cosmos/I18N/Core/II18NServiceCollection.cs
Original file line number Diff line number Diff line change
Expand Up @@ -31,23 +31,5 @@ public interface II18NServiceCollection {
/// <param name="servicesAction"></param>
/// <returns></returns>
II18NServiceCollection AddDependency(Action<IServiceCollection> servicesAction);

/// <summary>
/// Build
/// </summary>
/// <returns></returns>
IServiceProvider Build();

/// <summary>
/// Before build
/// </summary>
/// <param name="serviceAct"></param>
void BeforeBuild(Action<IServiceCollection> serviceAct);

/// <summary>
/// After build
/// </summary>
/// <param name="providerAct"></param>
void AfterBuild(Action<IServiceProvider> providerAct);
}
}

0 comments on commit ee7db2c

Please sign in to comment.