Package org.jboss.as.controller.descriptions.ModelDescriptionConstants

Examples of org.jboss.as.controller.descriptions.ModelDescriptionConstants.URL


    protected InputStream getContentInputStream(OperationContext operationContext, ModelNode operation) throws OperationFailedException {
        urlValidator.validate(operation);

        String urlSpec = operation.get(URL).asString();
        try {
            URL url = new URL(urlSpec);
            return url.openStream();
        } catch (MalformedURLException e) {
            throw new RuntimeException(urlSpec + " is not a valid URL", e);
        } catch (IOException e) {
            throw new RuntimeException("Error obtaining input stream from URL " + urlSpec, e);
        }
View Full Code Here


    protected InputStream getContentInputStream(OperationContext operationContext, ModelNode operation) throws OperationFailedException {
        urlValidator.validate(operation);

        String urlSpec = operation.get(URL).asString();
        try {
            URL url = new URL(urlSpec);
            return url.openStream();
        } catch (MalformedURLException e) {
            throw new RuntimeException(urlSpec + " is not a valid URL", e);
        } catch (IOException e) {
            throw new RuntimeException("Error obtaining input stream from URL " + urlSpec, e);
        }
View Full Code Here

    protected InputStream getContentInputStream(OperationContext operationContext, ModelNode operation) throws OperationFailedException {
        urlValidator.validate(operation);

        String urlSpec = operation.get(URL).asString();
        try {
            URL url = new URL(urlSpec);
            return url.openStream();
        } catch (MalformedURLException e) {
            throw new RuntimeException(urlSpec + " is not a valid URL", e);
        } catch (IOException e) {
            throw new RuntimeException("Error obtaining input stream from URL " + urlSpec, e);
        }
View Full Code Here

    protected InputStream getContentInputStream(OperationContext operationContext, ModelNode operation) throws OperationFailedException {
        urlValidator.validate(operation);

        String urlSpec = operation.get(URL).asString();
        try {
            URL url = new URL(urlSpec);
            return url.openStream();
        } catch (MalformedURLException e) {
            throw ServerMessages.MESSAGES.invalidDeploymentURL(urlSpec, e);
        } catch (IOException e) {
            throw ServerMessages.MESSAGES.problemOpeningStreamFromDeploymentURL(urlSpec, e);
        }
View Full Code Here

            message = MESSAGES.invalidByteStream();
        } else if (content.hasDefined(URL)) {
            final String urlSpec = content.get(URL).asString();
            try {
                message = MESSAGES.invalidUrlStream();
                in = new URL(urlSpec).openStream();
            } catch (MalformedURLException e) {
                throw createFailureException(message);
            } catch (IOException e) {
                throw createFailureException(message);
            }
View Full Code Here

    protected InputStream getContentInputStream(OperationContext operationContext, ModelNode operation) throws OperationFailedException {
        urlValidator.validate(operation);

        String urlSpec = operation.get(URL).asString();
        try {
            URL url = new URL(urlSpec);
            return url.openStream();
        } catch (MalformedURLException e) {
            throw new OperationFailedException(new ModelNode().set(MESSAGES.invalidUrl(urlSpec, e.toString())));
        } catch (IOException e) {
            throw new OperationFailedException(new ModelNode().set(MESSAGES.errorObtainingUrlStream(urlSpec, e.toString())));
        }
View Full Code Here

            in = new ByteArrayInputStream(operation.get(BYTES).asBytes());
        } else if (operation.hasDefined(URL)) {
            final String urlSpec = operation.get(URL).asString();
            try {
                message = MESSAGES.invalidUrlStream();
                in = new URL(urlSpec).openStream();
            } catch (MalformedURLException e) {
                throw createFailureException(message);
            } catch (IOException e) {
                throw createFailureException(message);
            }
View Full Code Here

    protected InputStream getContentInputStream(OperationContext operationContext, ModelNode operation) throws OperationFailedException {
        urlValidator.validate(operation);

        String urlSpec = operation.get(URL).asString();
        try {
            URL url = new URL(urlSpec);
            return url.openStream();
        } catch (MalformedURLException e) {
            throw new RuntimeException(urlSpec + " is not a valid URL", e);
        } catch (IOException e) {
            throw new RuntimeException("Error obtaining input stream from URL " + urlSpec, e);
        }
View Full Code Here

            in = new ByteArrayInputStream(operation.get(BYTES).asBytes());
        } else if (operation.hasDefined(URL)) {
            final String urlSpec = operation.get(URL).asString();
            try {
                message = "Invalid url stream.";
                in = new URL(urlSpec).openStream();
            } catch (MalformedURLException e) {
                throw createFailureException(message);
            } catch (IOException e) {
                throw createFailureException(message);
            }
View Full Code Here

            in = new ByteArrayInputStream(operation.get(BYTES).asBytes());
        } else if (operation.hasDefined(URL)) {
            final String urlSpec = operation.get(URL).asString();
            try {
                message = "Invalid url stream.";
                in = new URL(urlSpec).openStream();
            } catch (MalformedURLException e) {
                throw createFailureException(message);
            } catch (IOException e) {
                throw createFailureException(message);
            }
View Full Code Here

TOP

Related Classes of org.jboss.as.controller.descriptions.ModelDescriptionConstants.URL

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.