public static IDataBuilder AddDbLink(this IDataBuilder builder, IDbLinkProvider provider) { if (builder == null) { throw new ArgumentNullException(nameof(builder)); } if (provider == null) { throw new ArgumentNullException(nameof(provider)); } builder.Services.AddSingleton <IDbLinkProvider>(provider); return(builder); }
public void AddProvider(IDbLinkProvider provider) { _providers.Add(provider); }