Package org.fao.geonet.utils

Examples of org.fao.geonet.utils.GeonetHttpRequestFactory


         HttpGet req = new HttpGet(url);


    try {
        // Connect
            final GeonetHttpRequestFactory requestFactory = context.getBean(GeonetHttpRequestFactory.class);
            final ClientHttpResponse httpResponse = requestFactory.execute(req, new Function<HttpClientBuilder, Void>() {
                @Nullable
                @Override
                public Void apply(@Nullable HttpClientBuilder input) {
                    // set proxy from settings manager
                    Lib.net.setupProxy(context, input);
View Full Code Here


        // unescape \\n from metadataAbstract so they're properly sent to geoserver
        String metadataAbstract = Util.getParam(params, "metadataAbstract", "").replace("\\n","\n");
            MapServer m = repo.findOneById(nodeId);
            GeoServerNode g = new GeoServerNode(m);

            final GeonetHttpRequestFactory requestFactory = context.getBean(GeonetHttpRequestFactory.class);
            GeoServerRest gs = new GeoServerRest(requestFactory, g.getUrl(),
                    g.getUsername(), g.getUserpassword(),
                    g.getNamespacePrefix(), baseUrl);
   
        String file = Util.getParam(params, "file");
View Full Code Here

    if (!Lib.net.isUrlValid(params.capabUrl))
      throw new BadParameterEx("Capabilities URL", params.capabUrl);

    XmlRequest req;
    // Support both full GetCapbilities URL or CSW entry point
        final GeonetHttpRequestFactory requestFactory = context.getBean(GeonetHttpRequestFactory.class);
        if (params.capabUrl.contains("GetCapabilities")) {
            req = requestFactory.createXmlRequest(new URL(params.capabUrl));
    } else {
      req = requestFactory.createXmlRequest(new URL(params.capabUrl + (params.capabUrl.contains("?") ? "&" : "?") + GETCAPABILITIES_PARAMETERS));
    }

    Lib.net.setupProxy(context, req);

    if (params.useAccount)
View Full Code Here

TOP

Related Classes of org.fao.geonet.utils.GeonetHttpRequestFactory

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.