Start line:  
End line:  

Snippet Preview

Snippet HTML Code

Stack Overflow Questions
Copyright (C) 2013-2015 Dell, Inc ==================================================================== Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License. ====================================================================
package org.dasein.cloud.azure.compute.vm;

Created by vmunthiu on 12/11/2014.
public class AzureRoleDetails{
    private String serviceName;
    private String deploymentName;
    private String roleName;
    private AzureRoleDetails(String serviceNameString deploymentNameString roleName){
        this. = serviceName;
        this. = deploymentName;
        this. = roleName;
    }
    public static AzureRoleDetails fromString(String id){
        String[] parts = id.split(":");
        String serviceNamedeploymentNameroleName;
        if (parts.length == 3)    {
            serviceName = parts[0];
            deploymentName = parts[1];
            roleNameparts[2];
        }
        else ifparts.length == 2 ) {
            serviceName = parts[0];
            deploymentName = parts[1];
            roleName = serviceName;
        }
        else {
            serviceName = id;
            deploymentName = id;
            roleName = id;
        }
        return new AzureRoleDetails(serviceNamedeploymentNameroleName);
    }
    public String getServiceName() {
        return ;
    }
    public String getDeploymentName() {
        return ;
    }
    public String getRoleName() {
        return ;
    }
New to GrepCode? Check out our FAQ X