Package com.microsoft.windowsazure.management.mediaservices.models

Examples of com.microsoft.windowsazure.management.mediaservices.models.MediaServicesAccountCreateResponse


                }
                throw ex;
            }
           
            // Create Result
            MediaServicesAccountCreateResponse result = null;
            // Deserialize Response
            InputStream responseContent = httpResponse.getEntity().getContent();
            result = new MediaServicesAccountCreateResponse();
            ObjectMapper objectMapper = new ObjectMapper();
            JsonNode responseDoc = null;
            if (responseContent == null == false) {
                responseDoc = objectMapper.readTree(responseContent);
            }
           
            if (responseDoc != null) {
                MediaServicesCreatedAccount accountInstance = new MediaServicesCreatedAccount();
                result.setAccount(accountInstance);
               
                JsonNode accountIdValue = responseDoc.get("AccountId");
                if (accountIdValue != null) {
                    String accountIdInstance;
                    accountIdInstance = accountIdValue.getTextValue();
                    accountInstance.setAccountId(accountIdInstance);
                }
               
                JsonNode accountNameValue = responseDoc.get("AccountName");
                if (accountNameValue != null) {
                    String accountNameInstance;
                    accountNameInstance = accountNameValue.getTextValue();
                    accountInstance.setAccountName(accountNameInstance);
                }
               
                JsonNode subscriptionValue = responseDoc.get("Subscription");
                if (subscriptionValue != null) {
                    String subscriptionInstance;
                    subscriptionInstance = subscriptionValue.getTextValue();
                    accountInstance.setSubscriptionId(subscriptionInstance);
                }
            }
           
            result.setStatusCode(statusCode);
            if (httpResponse.getHeaders("x-ms-request-id").length > 0) {
                result.setRequestId(httpResponse.getFirstHeader("x-ms-request-id").getValue());
            }
           
            if (shouldTrace) {
                CloudTracing.exit(invocationId, result);
            }
View Full Code Here

TOP

Related Classes of com.microsoft.windowsazure.management.mediaservices.models.MediaServicesAccountCreateResponse

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.