org.mapfish.print.map.style.StyleParserPlugin Maven / Gradle / Ivy
Go to download
Show more of this group Show more artifacts with this name
Show all versions of print-lib Show documentation
Show all versions of print-lib Show documentation
Library for generating PDFs and images from online webmapping services
package org.mapfish.print.map.style;
import org.geotools.styling.Style;
import org.mapfish.print.config.Configuration;
import org.springframework.http.client.ClientHttpRequestFactory;
import java.util.Optional;
import javax.annotation.Nonnull;
import javax.annotation.Nullable;
/**
* A plugin used for loading {@link Style} objects from a string.
*
* The string might be json, css, url, whatever.
*/
public interface StyleParserPlugin {
/**
* Using the string load a style. The string can be from a URL, xml, css, whatever. If the string
* references a file it MUST be within a subdirectory of the configuration directory.
*
* @param configuration the configuration being used for the current print.
* @param clientHttpRequestFactory an factory for making http requests.
* @param styleString the string that provides the information for loading the style.
* @return if this plugin can create a style form the string then return the style otherwise
* Optional.absent().
*/
Optional