Package it.freedomotic.marketplace.util

Examples of it.freedomotic.marketplace.util.MarketPlacePlugin2


        //CookieSetting cS = parseCookie(loginJson);
        //String uid = parseUid(loginJson);

        //String test = postTaxonomySelectNodes("151",0);       
        //List<MarketPlacePlugin2> testlist = DrupalRestHelper.retrievePluginsByCategory("151");
        MarketPlacePlugin2 pluginTest = (MarketPlacePlugin2) DrupalRestHelper.retrievePluginPackage("http://www.freedomotic.com/rest/node/1196");
//        MarketPlacePlugin2 pluginTest = (MarketPlacePlugin2) DrupalRestHelper.retrievePluginPackage("http://www.freedomotic.com/rest/node/394");
//        putPlugin(cS, "394", pluginTest);
//        String nid = "394";
        //if (cS != null) {
        //String nid = postPlugin(cS, plugin);
View Full Code Here


        CookieSetting cS = drupal.parseCookie(loginJson);
        String userid = drupal.parseUid(loginJson);
        if (cS != null) {
            //first try to retrieve the plugin from the drupal site
            System.out.println("Retrieving " + nodeid + " from the marketplace");
            MarketPlacePlugin2 plugin = (MarketPlacePlugin2) DrupalRestHelper.retrievePluginPackage("http://www.freedomotic.com/rest/node/" + nodeid);
            if (plugin != null) {
                try {
                    File marketDirectory = new File(attachment);
                    File fileToUpload = findFileToUpload(marketDirectory);
                    if (fileToUpload != null) {

                        MarketPlaceFile pluginFile = drupal.postFile(cS, userid, marketDirectory.getAbsolutePath(), fileToUpload.getName());
                        plugin.addFile(pluginFile);
                        drupal.putPlugin(cS, nodeid, plugin);

                    } else {
                        throw new BuildException("No marketplace files in folder " + marketDirectory);
                    }
View Full Code Here

TOP

Related Classes of it.freedomotic.marketplace.util.MarketPlacePlugin2

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.