Package org.apache.sling.sitemap.spi.builder

## Interface SitemapExtensionProvider

All Known Implementing Classes:
  `AlternateLanguageExtensionProvider`, `GoogleImageExtensionProvider`, `GoogleNewsExtensionProvider`, `GoogleVideoExtensionProvider`

    @ConsumerType
    public interface SitemapExtensionProvider

To provide an implementation for a defined sub type of `Extension` an `SitemapExtensionProvider` needs to be registered as OSGI service.

In order to hide the implementation detail of an extension from the the consumer API, the return type of `newInstance()` is `AbstractExtension`, the provider facing API of the extension. However to use the returned instance, it has to also implement the extension sub type interface and be registered with it's full qualified class name.

There may be multiple `SitemapExtensionProvider`s using the same namespace. If so the one with the highest ranking according to the OSGI specification will define the namespace's prefix, which means that lower ranking services may use another prefix then they were registered with.

### Field Summary

Fields
`static String` `PROPERTY_EMPTY_TAG` An optional property to be set for extensions that only write attributes to the added xml tag and want to make use of an empty-tag.
`static String` `PROPERTY_INTERFACE` The mandatory property to set to the `Extension` sub-type.
`static String` `PROPERTY_LOCAL_NAME` The local tag name to use when adding the extension to the sitemap xml.
`static String` `PROPERTY_NAMESPACE` The xml namespace to use for the extension.
`static String` `PROPERTY_PREFIX` The xml namespace prefix to use for the extension.

### Method Summary

All Methods Instance Methods Abstract Methods
`@NotNull AbstractExtension` `newInstance()` Returns a new instance of the extension provided by the `SitemapExtensionProvider`.

### Field Detail

#### PROPERTY_INTERFACE

    static final String PROPERTY_INTERFACE

The mandatory property to set to the `Extension` sub-type.

See Also:
  Constant Field Values

#### PROPERTY_PREFIX

    static final String PROPERTY_PREFIX

The xml namespace prefix to use for the extension.

See Also:
  Constant Field Values

#### PROPERTY_NAMESPACE

    static final String PROPERTY_NAMESPACE

The xml namespace to use for the extension.

See Also:
  Constant Field Values

#### PROPERTY_LOCAL_NAME

    static final String PROPERTY_LOCAL_NAME

The local tag name to use when adding the extension to the sitemap xml.

See Also:
  Constant Field Values

#### PROPERTY_EMPTY_TAG

    static final String PROPERTY_EMPTY_TAG

An optional property to be set for extensions that only write attributes to the added xml tag and want to make use of an empty-tag. If not set an open and close tag will be written.

See Also:
  Constant Field Values

### Method Detail

#### newInstance

    @NotNull
    @NotNull AbstractExtension newInstance()

Returns a new instance of the extension provided by the `SitemapExtensionProvider`.

Returns: