Package org.springframework.extensions.webscripts

Examples of org.springframework.extensions.webscripts.WebScriptException


    this.configuration = configuration;
  }

  public void checkBundleInstallConfiguration() {
    if (!configuration.isHotDeployEnabled()) {
      throw new WebScriptException(
          HttpServletResponse.SC_FORBIDDEN,
          "osgi.container.control-panel.bundle-install is disabled"
      );
    }
  }
View Full Code Here


            return new JsonMessage(new JSONObject()
                .put("message", "osgi.container.control-panel.bundle-install is disabled"),
                HttpServletResponse.SC_FORBIDDEN);
        } else {
            if (JAR_MIME_TYPE.equalsIgnoreCase(contentType) == false) {
                throw new WebScriptException(HttpServletResponse.SC_BAD_REQUEST,
                    String.format("Can only accept content of type '%s'.", JAR_MIME_TYPE));
            }
            try {
                final Bundle bundle = bundleHelper.installBundleInRepository(content);
                return new JsonMessage(
View Full Code Here

TOP

Related Classes of org.springframework.extensions.webscripts.WebScriptException

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.