org.apache.felix.http.api

## Interface ExtHttpService

All Superinterfaces:
  org.osgi.service.http.HttpService

Deprecated.
The HTTP Whiteboard Service should be used instead.

    @Deprecated
    @ProviderType
    public interface ExtHttpService
    extends org.osgi.service.http.HttpService

The `ExtHttpService` allows other bundles in the OSGi environment to dynamically register resources, `Filter`s and `Servlet`s into the URI namespace of a HTTP service implementation. A bundle may later unregister its resources, `Filter`s or `Servlet`s.

See Also:
  `HttpContext`

### Method Summary

Methods
`void` `registerFilter(javax.servlet.Filter filter, String pattern, Dictionary initParams, int ranking, org.osgi.service.http.HttpContext context)` Deprecated. Allows for programmatic registration of a `Filter` instance.
`void` `unregisterFilter(javax.servlet.Filter filter)` Deprecated. Unregisters a previously registered `Filter`.
`void` `unregisterServlet(javax.servlet.Servlet servlet)` Deprecated. Unregisters a previously registered `Servlet`.

### Methods inherited from interface org.osgi.service.http.HttpService

`createDefaultHttpContext, registerResources, registerServlet, unregister`

### Method Detail

#### registerFilter

    void registerFilter(javax.servlet.Filter filter,
                      String pattern,
                      Dictionary initParams,
                      int ranking,
                      org.osgi.service.http.HttpContext context)
                        throws javax.servlet.ServletException

Deprecated.
Allows for programmatic registration of a `Filter` instance.

Parameters:
  `filter` - the `Filter` to register, cannot be `null`;
  `pattern` - the filter pattern to register the for, cannot be `null` and should be a valid regular expression;
  `initParams` - the initialization parameters passed to the given filter during its initialization, can be `null` in case no additional parameters should be provided;
  `ranking` - defines the order in which filters are called. A higher ranking causes the filter to be placed earlier in the filter chain;
  `context` - the optional `HttpContext` to associate with this filter, can be `null` in case a default context should be associated.
Throws:
  `javax.servlet.ServletException` - in case the registration failed, for example because the initialization failed or due any other problem;
  `IllegalArgumentException` - in case the given filter was `null`.

#### unregisterFilter

    void unregisterFilter(javax.servlet.Filter filter)

Deprecated.
Unregisters a previously registered `Filter`.

In case the given filter is not registered, this method is essentially a no-op.

Parameters:
  `filter` - the `Filter` to unregister, cannot be `null`.

#### unregisterServlet

    void unregisterServlet(javax.servlet.Servlet servlet)

Deprecated.
Unregisters a previously registered `Servlet`.

In case the given servlet is not registered, this method is essentially a no-op.

Parameters:
  `servlet` - the `Servlet` to unregister, cannot be `null`.