ConfigurationExtensions
A set of useful extensions for Configuration (or derived) objects.
Checks if the configuration holds any references to the given service.
Returns a new configuration that includes the given service.
Returns a new configuration that includes the given services.
public static IConfiguration With<TService>(this IConfiguration configuration, Func<IBrowsingContext, TService> creator)
Returns a new configuration that includes the given service creator.
Returns a new configuration that uses the culture with the provided
name.
Returns a new configuration that uses the given culture. Providing
null will reset the culture to the default one.
Registers the default cookie service if no other cookie service has
been registered yet.
public static IConfiguration WithDefaultLoader(this IConfiguration configuration, LoaderOptions setup = null)
Registers the default loader service, if no other loader has been registered yet.
Registeres the default encoding determination algorithm, as
specified by the W3C.
public static IConfiguration WithMetaRefresh(this IConfiguration configuration, Predicate<Url> shouldRefresh = null)
Registeres a handler to include the meta data refresh.
public static IConfiguration WithOnly<TService>(this IConfiguration configuration, TService service)
Returns a new configuration that includes only the given service,
excluding other instances or instance creators for the same service.
public static IConfiguration WithOnly<TService>(this IConfiguration configuration, Func<IBrowsingContext, TService> creator)
Returns a new configuration that includes only the given service
creator, excluding other instances or instance creators for the same
service.
Returns a new configuration that excludes the given service.
public static IConfiguration Without(this IConfiguration configuration, IEnumerable<object> services)
Returns a new configuration that excludes the given services.
Returns a new configuration that excludes the given service creator.