Package org.vfny.geoserver.wms

Examples of org.vfny.geoserver.wms.GetMapProducerFactorySpi


     */
    static GetMapProducer getDelegate(String outputFormat, WMSConfig config)
        throws WmsException {
        LOGGER.finer("request format is " + outputFormat);

        GetMapProducerFactorySpi mpf = null;
        Iterator mpfi = FactoryFinder.factories(GetMapProducerFactorySpi.class);

        while (mpfi.hasNext()) {
            mpf = (GetMapProducerFactorySpi) mpfi.next();

            if (mpf.canProduce(outputFormat)) {
                break;
            }

            mpf = null;
        }

        if (mpf == null) {
            throw new WmsException("There is no support for creating maps in "
                + outputFormat + " format", "InvalidFormat");
        }

       
        GetMapProducer producer = mpf.createMapProducer(outputFormat,config);

        return producer;
    }
View Full Code Here


     *
     * @return a Set<String> with the supported mime types.
     */
    public static Set getMapFormats() {
        Set mapFormats = new HashSet();
        GetMapProducerFactorySpi mpf;
        Iterator mpfi = FactoryFinder.factories(GetMapProducerFactorySpi.class);

        while (mpfi.hasNext()) {
            mpf = (GetMapProducerFactorySpi) mpfi.next();
            mapFormats.addAll(mpf.getSupportedFormats());
        }

        return mapFormats;
    }
View Full Code Here

TOP

Related Classes of org.vfny.geoserver.wms.GetMapProducerFactorySpi

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.