/*
 * CODENVY CONFIDENTIAL
 * __________________
 *
 *  [2012] - [2014] Codenvy, S.A.
 *  All Rights Reserved.
 *
 * NOTICE:  All information contained herein is, and remains
 * the property of Codenvy S.A. and its suppliers,
 * if any.  The intellectual and technical concepts contained
 * herein are proprietary to Codenvy S.A.
 * and its suppliers and may be covered by U.S. and Foreign Patents,
 * patents in process, and are protected by trade secret or copyright law.
 * Dissemination of this information or reproduction of this material
 * is strictly forbidden unless prior written permission is obtained
 * from Codenvy S.A..
 */
package com.codenvy.im.restlet;

/** @author Anatoliy Bazko */
public class InstallationManagerConfig {
    private String downloadDir;
    private String proxyPort;
    private String proxyUrl;

    public InstallationManagerConfig() {
    }

    public String getDownloadDir() {
        return downloadDir;
    }

    public void setDownloadDir(String downloadDir) {
        this.downloadDir = downloadDir;
    }

    public String getProxyUrl() {
        return proxyUrl;
    }

    public void setProxyUrl(String proxyUrl) {
        this.proxyUrl = proxyUrl;
    }

    public String getProxyPort() {
        return proxyPort.trim();
    }

    public void setProxyPort(String proxyPort) {
        this.proxyPort = proxyPort.trim();
    }

    public boolean checkOnEmptyConfig() {
        return checkEmptyParam(downloadDir) && checkEmptyParam(proxyUrl) && checkEmptyParam(proxyPort);
    }

    private boolean checkEmptyParam(String param) {
        return param == null || param.isEmpty();
    }
}

@@ -1185,34 +1185,67 @@
 xyUrl = proxyUrl
+ != null ? proxyUrl.trim() : null
 ;%0A
-
     %7D%0A%0A    publi
@@ -1286,39 +1286,32 @@
 return proxyPort
-.trim()
 ;%0A    %7D%0A%0A    pub
@@ -1386,23 +1386,50 @@
 roxyPort
-.trim()
+ != null ? proxyPort.trim() : null
 ;%0A    %7D%0A

Add config command