http://git-wip-us.apache.org/repos/asf/jclouds-labs/blob/eb990020/azurecompute/src/main/java/org/jclouds/azurecompute/domain/ReservedIPAddressParams.java ---------------------------------------------------------------------- diff --git a/azurecompute/src/main/java/org/jclouds/azurecompute/domain/ReservedIPAddressParams.java b/azurecompute/src/main/java/org/jclouds/azurecompute/domain/ReservedIPAddressParams.java deleted file mode 100644 index 9daaf12..0000000 --- a/azurecompute/src/main/java/org/jclouds/azurecompute/domain/ReservedIPAddressParams.java +++ /dev/null @@ -1,104 +0,0 @@ -/* - * Licensed to the Apache Software Foundation (ASF) under one or more - * contributor license agreements. See the NOTICE file distributed with - * this work for additional information regarding copyright ownership. - * The ASF licenses this file to You 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.jclouds.azurecompute.domain; - -import com.google.auto.value.AutoValue; -import org.jclouds.javax.annotation.Nullable; - -/** - * The Create Reserved IP Address operation reserves an IPv4 address for the specified subscription. For more - * information, see Reserved IP Addresses. You can use a small number of reserved IP addresses for free, but unused - * reserved IP addresses and a number of addresses above the limit will incur charges. - * - * @see <a href="https://msdn.microsoft.com/en-us/library/azure/dn722413.aspx">Create Reserved IP Address</a> - */ -@AutoValue -public abstract class ReservedIPAddressParams { - - ReservedIPAddressParams() { - } // For AutoValue only! - - /** - * Specifies the name for the reserved IP address. - * - * @return name. - */ - public abstract String name(); - - /** - * Specifies a label for the reserved IP address. The label can be up to 100 characters long and can be used for your - * tracking purposes. - * - * @return label. - */ - @Nullable - public abstract String label(); - - /** - * Specifies the location of the reserved IP address. This should be the same location that is assigned to the cloud - * service containing the deployment that will use the reserved IP address. - * - * @return location. - */ - public abstract String location(); - - public Builder toBuilder() { - return builder().fromReservedIPAddressParams(this); - } - - public static Builder builder() { - return new Builder(); - } - - public static final class Builder { - - private String name; - - private String label; - - private String location; - - public Builder name(final String data) { - this.name = data; - return this; - } - - public Builder label(final String format) { - this.label = format; - return this; - } - - public Builder location(final String password) { - this.location = password; - return this; - } - - public ReservedIPAddressParams build() { - return ReservedIPAddressParams.create(name, label, location); - } - - public Builder fromReservedIPAddressParams(final ReservedIPAddressParams in) { - return name(in.name()) - .label(in.label()) - .location(in.location()); - } - } - - private static ReservedIPAddressParams create(final String name, final String label, final String location) { - return new AutoValue_ReservedIPAddressParams(name, label, location); - } -}
http://git-wip-us.apache.org/repos/asf/jclouds-labs/blob/eb990020/azurecompute/src/main/java/org/jclouds/azurecompute/domain/Role.java ---------------------------------------------------------------------- diff --git a/azurecompute/src/main/java/org/jclouds/azurecompute/domain/Role.java b/azurecompute/src/main/java/org/jclouds/azurecompute/domain/Role.java deleted file mode 100644 index 5c28c23..0000000 --- a/azurecompute/src/main/java/org/jclouds/azurecompute/domain/Role.java +++ /dev/null @@ -1,310 +0,0 @@ -/* - * Licensed to the Apache Software Foundation (ASF) under one or more - * contributor license agreements. See the NOTICE file distributed with - * this work for additional information regarding copyright ownership. - * The ASF licenses this file to You 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.jclouds.azurecompute.domain; - -import static com.google.common.collect.ImmutableList.copyOf; -import java.net.URI; -import java.util.List; - -import org.jclouds.javax.annotation.Nullable; - -import com.google.auto.value.AutoValue; - -/** - * @see <a href="https://msdn.microsoft.com/en-us/library/azure/jj157193.aspx">Role</a> - */ -@AutoValue -public abstract class Role { - - @AutoValue - public abstract static class ConfigurationSet { - - @AutoValue - public abstract static class InputEndpoint { - - @AutoValue - public abstract static class LoadBalancerProbe { - - public abstract String path(); - - public abstract int port(); - - public abstract String protocol(); - - LoadBalancerProbe() { // For AutoValue only! - } - - public static LoadBalancerProbe create(final String path, final int port, final String protocol) { - return new AutoValue_Role_ConfigurationSet_InputEndpoint_LoadBalancerProbe(path, port, protocol); - } - } - - public abstract int localPort(); - - public abstract String name(); - - public abstract Integer port(); - - public abstract String protocol(); - - @Nullable - public abstract String vip(); - - public abstract Boolean enableDirectServerReturn(); - - @Nullable - public abstract String loadBalancerName(); - - @Nullable - public abstract LoadBalancerProbe loadBalancerProbe(); - - @Nullable - public abstract Integer idleTimeoutInMinutes(); - - InputEndpoint() { // For AutoValue only! - } - - public static InputEndpoint create( - final String name, final String protocol, final int localPort, final int port, - final String vip, final boolean enableDirectServerReturn, final String loadBalancerName, - final LoadBalancerProbe loadBalancerProbe, final Integer idleTimeoutInMinutes) { - - return new AutoValue_Role_ConfigurationSet_InputEndpoint(localPort, name, port, protocol, vip, - enableDirectServerReturn, loadBalancerName, loadBalancerProbe, idleTimeoutInMinutes); - } - } - - @AutoValue - public abstract static class SubnetName { - - @Nullable - public abstract String name(); - - SubnetName() { // For AutoValue only! - } - - public static SubnetName create(final String name) { - return new AutoValue_Role_ConfigurationSet_SubnetName(name); - } - } - - @AutoValue - public abstract static class PublicIP { - - public abstract String name(); - - public abstract int idleTimeoutInMinutes(); - - PublicIP() { // For AutoValue only! - } - - public static PublicIP create(final String name, final int idleTimeoutInMinutes) { - return new AutoValue_Role_ConfigurationSet_PublicIP(name, idleTimeoutInMinutes); - } - } - - public abstract String configurationSetType(); - - public abstract List<InputEndpoint> inputEndpoints(); - - @Nullable - public abstract List<SubnetName> subnetNames(); - - @Nullable - public abstract String staticVirtualNetworkIPAddress(); - - @Nullable - public abstract List<PublicIP> publicIPs(); - - @Nullable - public abstract String networkSecurityGroup(); - - ConfigurationSet() { // For AutoValue only! - } - - public static ConfigurationSet create( - final String configurationSetType, final List<InputEndpoint> inputEndpoints, - final List<SubnetName> subnetNames, final String staticVirtualNetworkIPAddress, - final List<PublicIP> publicIPs, final String networkSecurityGroup) { - - return new AutoValue_Role_ConfigurationSet(configurationSetType, inputEndpoints, subnetNames, - staticVirtualNetworkIPAddress, publicIPs, networkSecurityGroup); - } - } - - @AutoValue - public abstract static class ResourceExtensionReference { - - @AutoValue - public abstract static class ResourceExtensionParameterValue { - - public abstract String key(); - - public abstract String value(); - - public abstract String type(); - - ResourceExtensionParameterValue() { // For AutoValue only! - } - - public static ResourceExtensionParameterValue create( - final String key, final String value, final String type) { - - return new AutoValue_Role_ResourceExtensionReference_ResourceExtensionParameterValue(key, value, type); - } - } - - @Nullable public abstract String referenceName(); - - @Nullable public abstract String publisher(); - - @Nullable public abstract String name(); - - @Nullable public abstract String version(); - - @Nullable public abstract List<ResourceExtensionParameterValue> resourceExtensionParameterValues(); - - @Nullable public abstract String state(); - - ResourceExtensionReference() { // For AutoValue only! - } - - public static ResourceExtensionReference create( - final String referenceName, final String publisher, final String name, final String version, - final List<ResourceExtensionParameterValue> resourceExtensionParameterValues, final String state) { - - return new AutoValue_Role_ResourceExtensionReference(referenceName, publisher, name, version, - resourceExtensionParameterValues, state); - } - } - - @AutoValue - public abstract static class OSVirtualHardDisk { - - public abstract String hostCaching(); - - public abstract String diskName(); - - @Nullable - public abstract Integer lun(); - - @Nullable - public abstract Integer logicalDiskSizeInGB(); - - public abstract URI mediaLink(); - - @Nullable - public abstract String sourceImageName(); - - public abstract OSImage.Type os(); - - OSVirtualHardDisk() { // For AutoValue only! - } - - public static OSVirtualHardDisk create(final String hostCaching, final String diskName, final Integer lun, - final Integer logicalDiskSizeInGB, final URI mediaLink, final String sourceImageName, - final OSImage.Type os) { - - return new AutoValue_Role_OSVirtualHardDisk(hostCaching, diskName, lun, logicalDiskSizeInGB, mediaLink, - sourceImageName, os); - } - } - - /** - * Represents the name of the Virtual Machine. - */ - public abstract String roleName(); - - /** - * Specifies the type of role that is used. For Virtual Machines, this must be PersistentVMRole. - */ - public abstract String roleType(); - - /** - * Specifies the name of the VM Image that was used to create the Virtual Machine. - */ - @Nullable - public abstract String vmImage(); - - /** - * Specifies the path to the VHD files that are associated with the VM Image. - */ - @Nullable - public abstract String mediaLocation(); - - /** - * Contains a collection of configuration sets that define system and application settings. - */ - public abstract List<ConfigurationSet> configurationSets(); - - /** - * Optional. Contains a collection of resource extensions that are installed on the Virtual Machine. This element is - * used if ProvisionGuestAgent is set to true. - */ - @Nullable - public abstract List<ResourceExtensionReference> resourceExtensionReferences(); - - /** - * Specifies the name of a collection of Virtual Machines. Virtual Machines specified in the same availability set - * are allocated to different nodes to maximize availability. - */ - @Nullable - public abstract String availabilitySetName(); - - /** - * Contains the parameters that were used to add a data disk to a Virtual Machine. - */ - @Nullable - public abstract List<DataVirtualHardDisk> dataVirtualHardDisks(); - - /** - * Contains the parameters that were used to create the operating system disk for a Virtual Machine. - */ - public abstract OSVirtualHardDisk osVirtualHardDisk(); - - /** - * Specifies the size of the Virtual Machine. - */ - public abstract RoleSize.Type roleSize(); - - /** - * Optional. Indicates whether the VM Agent is installed on the Virtual Machine. To run a resource extension in a - * Virtual Machine, this service must be installed. - * - * @return true or false - */ - @Nullable - public abstract Boolean provisionGuestAgent(); - - /** - * Specifies the read-only thumbprint of the certificate that is used with the HTTPS listener for WinRM. - */ - @Nullable - public abstract String defaultWinRmCertificateThumbprint(); - - public static Role create(final String roleName, final String roleType, final String vmImage, - final String mediaLocation, final List<ConfigurationSet> configurationSets, - final List<ResourceExtensionReference> resourceExtensionReferences, - final String availabilitySetName, final List<DataVirtualHardDisk> dataVirtualHardDisks, - final OSVirtualHardDisk osVirtualHardDisk, final RoleSize.Type roleSize, final Boolean provisionGuestAgent, - final String defaultWinRmCertificateThumbprint) { - - return new AutoValue_Role(roleName, roleType, vmImage, mediaLocation, copyOf(configurationSets), - copyOf(resourceExtensionReferences), availabilitySetName, copyOf(dataVirtualHardDisks), - osVirtualHardDisk, roleSize, provisionGuestAgent, defaultWinRmCertificateThumbprint); - } -} http://git-wip-us.apache.org/repos/asf/jclouds-labs/blob/eb990020/azurecompute/src/main/java/org/jclouds/azurecompute/domain/RoleSize.java ---------------------------------------------------------------------- diff --git a/azurecompute/src/main/java/org/jclouds/azurecompute/domain/RoleSize.java b/azurecompute/src/main/java/org/jclouds/azurecompute/domain/RoleSize.java deleted file mode 100644 index 3b6290e..0000000 --- a/azurecompute/src/main/java/org/jclouds/azurecompute/domain/RoleSize.java +++ /dev/null @@ -1,161 +0,0 @@ -/* - * Licensed to the Apache Software Foundation (ASF) under one or more - * contributor license agreements. See the NOTICE file distributed with - * this work for additional information regarding copyright ownership. - * The ASF licenses this file to You 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.jclouds.azurecompute.domain; - -import org.jclouds.javax.annotation.Nullable; - -import com.google.auto.value.AutoValue; - -/** - * A Role Size that is available in a given subscription. - * - * @see <a href="https://msdn.microsoft.com/en-us/library/azure/dn469422.aspx" >api</a> - */ -@AutoValue -public abstract class RoleSize { - - public enum Type { - - BASIC_A0("Basic_A0"), - BASIC_A1("Basic_A1"), - BASIC_A2("Basic_A2"), - BASIC_A3("Basic_A3"), - BASIC_A4("Basic_A4"), - A0("A0"), - A1("A1"), - A2("A2"), - A3("A3"), - A4("A4"), - A5("A5"), - A6("A6"), - A7("A7"), - A8("A8"), - A9("A9"), - A10("A10"), - A11("A11"), - STANDARD_A0("Standard_A0"), - STANDARD_A1("Standard_A1"), - STANDARD_A2("Standard_A2"), - STANDARD_A3("Standard_A3"), - STANDARD_A4("Standard_A4"), - STANDARD_A5("Standard_A5"), - STANDARD_A6("Standard_A6"), - STANDARD_A7("Standard_A7"), - STANDARD_A8("Standard_A8"), - STANDARD_A9("Standard_A9"), - STANDARD_D1("Standard_D1"), - STANDARD_D2("Standard_D2"), - STANDARD_D3("Standard_D3"), - STANDARD_D4("Standard_D4"), - STANDARD_D11("Standard_D11"), - STANDARD_D12("Standard_D12"), - STANDARD_D13("Standard_D13"), - STANDARD_D14("Standard_D14"), - STANDARD_G1("Standard_G1"), - STANDARD_G2("Standard_G2"), - STANDARD_G3("Standard_G3"), - STANDARD_G4("Standard_G4"), - STANDARD_G5("Standard_G5"), - EXTRASMALL("ExtraSmall"), - SMALL("Small"), - MEDIUM("Medium"), - LARGE("Large"), - EXTRALARGE("ExtraLarge"), - UNRECOGNIZED("UNRECOGNIZED"); - - private final String text; - - Type(final String text) { - this.text = text; - } - - public String getText() { - return this.text; - } - - public static Type fromString(final String text) { - if (text != null) { - for (Type type : Type.values()) { - if (text.equalsIgnoreCase(type.text)) { - return type; - } - } - } - return UNRECOGNIZED; - } - } - - RoleSize() { - } // For AutoValue only! - - /** - * The name of the role size. - */ - public abstract Type name(); - - /** - * The description of the role size. - */ - @Nullable - public abstract String label(); - - /** - * The number of cores that are available in the role size. - */ - public abstract Integer cores(); - - /** - * The amount of memory that is available in the role size. - */ - public abstract Integer memoryInMb(); - - /** - * Indicates whether the role size supports web roles or worker roles. - */ - public abstract Boolean supportedByWebWorkerRoles(); - - /** - * Indicates whether the role size supports Virtual Machines. - */ - public abstract Boolean supportedByVirtualMachines(); - - /** - * The maximum number of data disks that can be attached to the role. - */ - public abstract Integer maxDataDiskCount(); - - /** - * The size of the resource disk for a web role or worker role. - */ - public abstract Integer webWorkerResourceDiskSizeInMb(); - - /** - * The size of the resource disk for a Virtual Machine. - */ - public abstract Integer virtualMachineResourceDiskSizeInMb(); - - public static RoleSize create(final Type name, final String label, final Integer cores, - final Integer memoryInMb, final Boolean supportedByWebWorkerRoles, - final Boolean supportedByVirtualMachines, final Integer maxDataDiskCount, - final Integer webWorkerResourceDiskSizeInMb, final Integer virtualMachineResourceDiskSizeInMb) { - - return new AutoValue_RoleSize(name, label, cores, memoryInMb, - supportedByWebWorkerRoles, supportedByVirtualMachines, maxDataDiskCount, webWorkerResourceDiskSizeInMb, - virtualMachineResourceDiskSizeInMb); - } - -} http://git-wip-us.apache.org/repos/asf/jclouds-labs/blob/eb990020/azurecompute/src/main/java/org/jclouds/azurecompute/domain/Rule.java ---------------------------------------------------------------------- diff --git a/azurecompute/src/main/java/org/jclouds/azurecompute/domain/Rule.java b/azurecompute/src/main/java/org/jclouds/azurecompute/domain/Rule.java deleted file mode 100644 index a58cb3b..0000000 --- a/azurecompute/src/main/java/org/jclouds/azurecompute/domain/Rule.java +++ /dev/null @@ -1,146 +0,0 @@ -/* - * Licensed to the Apache Software Foundation (ASF) under one or more - * contributor license agreements. See the NOTICE file distributed with - * this work for additional information regarding copyright ownership. - * The ASF licenses this file to You 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.jclouds.azurecompute.domain; - -import org.jclouds.javax.annotation.Nullable; - -import com.google.auto.value.AutoValue; - -@AutoValue -public abstract class Rule { - - public enum Action { - - Allow, - Deny, - UNRECOGNIZED; - - public static Action fromString(final String text) { - if (text != null) { - for (Action action : Action.values()) { - if (text.equalsIgnoreCase(action.name())) { - return action; - } - } - } - return UNRECOGNIZED; - } - } - - public enum Type { - - Inbound, - Outbound, - UNRECOGNIZED; - - public static Type fromString(final String text) { - if (text != null) { - for (Type type : Type.values()) { - if (text.equalsIgnoreCase(type.name())) { - return type; - } - } - } - return UNRECOGNIZED; - } - } - - public enum Protocol { - - TCP("TCP"), - UDP("UDP"), - ALL("*"), - UNRECOGNIZED(""); - - private final String value; - - Protocol(final String value) { - this.value = value; - } - - public static Protocol fromString(final String text) { - if (text != null) { - for (Protocol protocol : Protocol.values()) { - if (text.equalsIgnoreCase(protocol.value)) { - return protocol; - } - } - } - return UNRECOGNIZED; - } - - public String getValue() { - return value; - } - } - - public abstract String name(); - - public abstract Type type(); - - public abstract String priority(); - - public abstract Action action(); - - public abstract String sourceAddressPrefix(); - - public abstract String sourcePortRange(); - - public abstract String destinationAddressPrefix(); - - public abstract String destinationPortRange(); - - public abstract Protocol protocol(); - - public abstract String state(); - - @Nullable - public abstract Boolean isDefault(); - - Rule() { - } // For AutoValue only! - - /** - * Use this method to create a new rule to be added to a network security group. - * @param name - * @param type - * @param priority - * @param action - * @param sourceAddressPrefix - * @param sourcePortRange - * @param destinationAddressPrefix - * @param destinationPortRange - * @param protocol - * @return - */ - public static Rule create(final String name, final Type type, final String priority, final Action action, - final String sourceAddressPrefix, final String sourcePortRange, final String destinationAddressPrefix, - final String destinationPortRange, final Protocol protocol) { - - return new AutoValue_Rule(name, type, priority, action, sourceAddressPrefix, sourcePortRange, - destinationAddressPrefix, destinationPortRange, protocol, "Active", null); - } - - public static Rule create(final String name, final Type type, final String priority, final Action action, - final String sourceAddressPrefix, final String sourcePortRange, final String destinationAddressPrefix, - final String destinationPortRange, final Protocol protocol, final String state, final Boolean isDefault) { - - return new AutoValue_Rule(name, type, priority, action, sourceAddressPrefix, sourcePortRange, - destinationAddressPrefix, destinationPortRange, protocol, state, isDefault); - } - -} http://git-wip-us.apache.org/repos/asf/jclouds-labs/blob/eb990020/azurecompute/src/main/java/org/jclouds/azurecompute/domain/ServiceCertificate.java ---------------------------------------------------------------------- diff --git a/azurecompute/src/main/java/org/jclouds/azurecompute/domain/ServiceCertificate.java b/azurecompute/src/main/java/org/jclouds/azurecompute/domain/ServiceCertificate.java deleted file mode 100644 index 1fe0081..0000000 --- a/azurecompute/src/main/java/org/jclouds/azurecompute/domain/ServiceCertificate.java +++ /dev/null @@ -1,74 +0,0 @@ -/* - * Licensed to the Apache Software Foundation (ASF) under one or more - * contributor license agreements. See the NOTICE file distributed with - * this work for additional information regarding copyright ownership. - * The ASF licenses this file to You 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.jclouds.azurecompute.domain; - -import com.google.auto.value.AutoValue; -import java.net.URI; -import org.jclouds.javax.annotation.Nullable; - -/** - * Cloud service certifcate. - * - * @see <a href="https://msdn.microsoft.com/en-us/library/azure/ee795178.aspx" >ServiceCertificate</a> - */ -@AutoValue -public abstract class ServiceCertificate { - - ServiceCertificate() { - } // For AutoValue only! - - /** - * The Service Management API request URI used to perform Get Service Certificate requests against the certificate - * store. - * - * @return service certificate URL. - */ - @Nullable - public abstract URI url(); - - /** - * The X509 certificate thumb print property of the service certificate. - * - * @return thumbprint of the service certificate. - */ - @Nullable - public abstract String thumbprint(); - - /** - * The algorithm that was used to hash the service certificate. Currently SHA-1 is the only supported algorithm. - * - * @return thumbprint algorithm of the service certificate. - */ - @Nullable - public abstract String thumbprintAlgorithm(); - - /** - * The public part of the service certificate as a base-64 encoded .cer file. - * - * @return base-64 encoded certificate. - */ - public abstract String data(); - - public static ServiceCertificate create( - final URI url, - final String thumbprint, - final String thumbprintAlgorithm, - final String data) { - - return new AutoValue_ServiceCertificate(url, thumbprint, thumbprintAlgorithm, data); - } -} http://git-wip-us.apache.org/repos/asf/jclouds-labs/blob/eb990020/azurecompute/src/main/java/org/jclouds/azurecompute/domain/ServiceCertificateParams.java ---------------------------------------------------------------------- diff --git a/azurecompute/src/main/java/org/jclouds/azurecompute/domain/ServiceCertificateParams.java b/azurecompute/src/main/java/org/jclouds/azurecompute/domain/ServiceCertificateParams.java deleted file mode 100644 index b739a7e..0000000 --- a/azurecompute/src/main/java/org/jclouds/azurecompute/domain/ServiceCertificateParams.java +++ /dev/null @@ -1,100 +0,0 @@ -/* - * Licensed to the Apache Software Foundation (ASF) under one or more - * contributor license agreements. See the NOTICE file distributed with - * this work for additional information regarding copyright ownership. - * The ASF licenses this file to You 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.jclouds.azurecompute.domain; - -import com.google.auto.value.AutoValue; -import org.jclouds.javax.annotation.Nullable; - -/** - * To create a new service certifcate. - * - * @see <a href="https://msdn.microsoft.com/en-us/library/azure/ee460817.aspx">docs</a> - */ -@AutoValue -public abstract class ServiceCertificateParams { - - ServiceCertificateParams() { - } // For AutoValue only! - - /** - * The public part of the service certificate as a base-64 encoded .cer file. - * - * @return base-64 encoded certificate. - */ - public abstract String data(); - - /** - * Required. Specifies the format of the service certificate. Possible values are: pfx, cer. - * - * @return certificate format. - */ - public abstract String format(); - - /** - * Specifies the password for a .pfx certificate. A .cer certificate does not require a password. - * - * @return certificate password. - */ - @Nullable - public abstract String password(); - - public Builder toBuilder() { - return builder().fromServiceCertificateParams(this); - } - - public static Builder builder() { - return new Builder(); - } - - public static final class Builder { - - private String data; - - private String format; - - private String password; - - public Builder data(final String data) { - this.data = data; - return this; - } - - public Builder format(final String format) { - this.format = format; - return this; - } - - public Builder password(final String password) { - this.password = password; - return this; - } - - public ServiceCertificateParams build() { - return ServiceCertificateParams.create(data, format, password); - } - - public Builder fromServiceCertificateParams(final ServiceCertificateParams in) { - return data(in.data()) - .format(in.format()) - .password(in.password()); - } - } - - private static ServiceCertificateParams create(final String data, final String format, final String password) { - return new AutoValue_ServiceCertificateParams(data, format, password); - } -} http://git-wip-us.apache.org/repos/asf/jclouds-labs/blob/eb990020/azurecompute/src/main/java/org/jclouds/azurecompute/domain/StorageService.java ---------------------------------------------------------------------- diff --git a/azurecompute/src/main/java/org/jclouds/azurecompute/domain/StorageService.java b/azurecompute/src/main/java/org/jclouds/azurecompute/domain/StorageService.java deleted file mode 100644 index 701ec2c..0000000 --- a/azurecompute/src/main/java/org/jclouds/azurecompute/domain/StorageService.java +++ /dev/null @@ -1,243 +0,0 @@ -/* - * Licensed to the Apache Software Foundation (ASF) under one or more - * contributor license agreements. See the NOTICE file distributed with - * this work for additional information regarding copyright ownership. - * The ASF licenses this file to You 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.jclouds.azurecompute.domain; - -import com.google.auto.value.AutoValue; -import com.google.common.collect.ImmutableList; -import com.google.common.collect.ImmutableMap; -import java.net.URL; -import java.util.Date; -import java.util.List; -import java.util.Map; -import org.jclouds.javax.annotation.Nullable; - -@AutoValue -public abstract class StorageService { - - public enum AccountType { - - Standard_LRS, - Standard_ZRS, - Standard_GRS, - Standard_RAGRS, - Premium_LRS, - UNRECOGNIZED; - - public static AccountType fromString(final String text) { - if (text != null) { - for (AccountType type : AccountType.values()) { - if (text.equalsIgnoreCase(type.name())) { - return type; - } - } - } - return UNRECOGNIZED; - } - } - - public enum RegionStatus { - - Available, - Unavailable, - UNRECOGNIZED; - - public static RegionStatus fromString(final String text) { - if (text != null) { - for (RegionStatus status : RegionStatus.values()) { - if (text.equalsIgnoreCase(status.name())) { - return status; - } - } - } - return UNRECOGNIZED; - } - - } - - public enum Status { - - Creating, - Created, - Deleting, - Deleted, - Changing, - ResolvingDns, - UNRECOGNIZED; - - public static Status fromString(final String text) { - if (text != null) { - for (Status status : Status.values()) { - if (text.equalsIgnoreCase(status.name())) { - return status; - } - } - } - return UNRECOGNIZED; - } - } - - @AutoValue - public abstract static class StorageServiceProperties { - - StorageServiceProperties() { - } // For AutoValue only! - - /** - * A description for the storage account. The description can be up to 1024 characters in length. - */ - @Nullable - public abstract String description(); - - /** - * Required if Location is not specified. The name of an existing affinity group associated with this - * subscription. - */ - @Nullable - public abstract String affinityGroup(); - - /** - * Required if AffinityGroup is not specified. The location where the storage account will be created. - */ - @Nullable - public abstract String location(); - - /** - * A name for the hosted service that is base-64 encoded. The name can be up to 100 characters in length. The name - * can be used identify the storage account for your tracking purposes - */ - public abstract String label(); - - /** - * The status of the storage account. - */ - public abstract Status status(); - - /** - * Specifies the endpoints of the storage account. - */ - @Nullable - public abstract List<URL> endpoints(); - - /** - * Indicates the primary geographical region in which the storage account exists at this time. - */ - @Nullable - public abstract String geoPrimaryRegion(); - - /** - * Indicates whether the primary storage region is available. - */ - @Nullable - public abstract RegionStatus statusOfPrimary(); - - /** - * A timestamp that indicates the most recent instance of a failover to the secondary region. In case of multiple - * failovers only the latest failover date and time maintained - */ - @Nullable - public abstract Date lastGeoFailoverTime(); - - /** - * Indicates the geographical region in which the storage account is being replicated. - */ - @Nullable - public abstract String geoSecondaryRegion(); - - /** - * Indicates whether the secondary storage region is available. - */ - @Nullable - public abstract RegionStatus statusOfSecondary(); - - /** - * Specifies the time that the storage account was created. - */ - public abstract Date creationTime(); - - /** - * Specifies the custom domains that are associated with the storage account. - */ - @Nullable - public abstract List<String> customDomains(); - - /** - * Specifies the secondary endpoints of the storage account. - */ - @Nullable - public abstract List<URL> secondaryEndpoints(); - - /** - * Specifies whether the account supports locally-redundant storage, geo-redundant storage, zone-redundant - * storage, or read access geo-redundant storage. - */ - public abstract AccountType accountType(); - - public static StorageServiceProperties create(final String description, final String affinityGroup, - final String location, final String label, final Status status, final List<URL> endpoints, - final String geoPrimaryRegion, final RegionStatus statusOfPrimary, - final Date lastGeoFailoverTime, final String geoSecondaryRegion, final RegionStatus statusOfSecondary, - final Date creationTime, final List<String> customDomains, final List<URL> secondaryEndpoints, - final AccountType accountType) { - - return new AutoValue_StorageService_StorageServiceProperties(description, affinityGroup, location, - label, status, endpoints == null ? null : ImmutableList.copyOf(endpoints), - geoPrimaryRegion, statusOfPrimary, lastGeoFailoverTime, geoSecondaryRegion, statusOfSecondary, - creationTime, customDomains, - secondaryEndpoints == null ? null : ImmutableList.copyOf(secondaryEndpoints), accountType); - } - } - - StorageService() { - } // For AutoValue only! - - /** - * Specifies the URI of the storage account. - */ - public abstract URL url(); - - /** - * Specifies the name of the storage account. This name is the DNS prefix name and can be used to access blobs, - * queues, and tables in the storage account. - */ - public abstract String serviceName(); - - /** - * Specifies the properties of the storage account. - */ - public abstract StorageServiceProperties storageServiceProperties(); - - /** - * Specifies the name and value of an extended property that was added to the storage account. - */ - @Nullable - public abstract Map<String, String> extendedProperties(); - - /** - * Indicates whether the storage account is able to perform virtual machine related operations. If so, this element - * returns a string containing PersistentVMRole. Otherwise, this element will not be present. - */ - @Nullable - public abstract String capability(); - - public static StorageService create(final URL url, final String serviceName, - final StorageServiceProperties storageServiceProperties, final Map<String, String> extendedProperties, - final String capability) { - - return new AutoValue_StorageService(url, serviceName, storageServiceProperties, - extendedProperties == null ? null : ImmutableMap.copyOf(extendedProperties), capability); - } -} http://git-wip-us.apache.org/repos/asf/jclouds-labs/blob/eb990020/azurecompute/src/main/java/org/jclouds/azurecompute/domain/StorageServiceKeys.java ---------------------------------------------------------------------- diff --git a/azurecompute/src/main/java/org/jclouds/azurecompute/domain/StorageServiceKeys.java b/azurecompute/src/main/java/org/jclouds/azurecompute/domain/StorageServiceKeys.java deleted file mode 100644 index 43f2ce0..0000000 --- a/azurecompute/src/main/java/org/jclouds/azurecompute/domain/StorageServiceKeys.java +++ /dev/null @@ -1,54 +0,0 @@ -/* - * Licensed to the Apache Software Foundation (ASF) under one or more - * contributor license agreements. See the NOTICE file distributed with - * this work for additional information regarding copyright ownership. - * The ASF licenses this file to You 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.jclouds.azurecompute.domain; - -import com.google.auto.value.AutoValue; -import java.net.URL; - -@AutoValue -public abstract class StorageServiceKeys { - - public enum KeyType { - - Primary, - Secondary; - - } - - StorageServiceKeys() { - } // For AutoValue only! - - /** - * The Service Management API request URI used to perform Get Storage Account Properties requests against the storage - * account. - */ - public abstract URL url(); - - /** - * The primary access key for the storage account. - */ - public abstract String primary(); - - /** - * The secondary access key for the storage account. - */ - public abstract String secondary(); - - public static StorageServiceKeys create(final URL url, final String primary, final String secondary) { - return new AutoValue_StorageServiceKeys(url, primary, secondary); - } -} http://git-wip-us.apache.org/repos/asf/jclouds-labs/blob/eb990020/azurecompute/src/main/java/org/jclouds/azurecompute/domain/UpdateAffinityGroupParams.java ---------------------------------------------------------------------- diff --git a/azurecompute/src/main/java/org/jclouds/azurecompute/domain/UpdateAffinityGroupParams.java b/azurecompute/src/main/java/org/jclouds/azurecompute/domain/UpdateAffinityGroupParams.java deleted file mode 100644 index 7beddb5..0000000 --- a/azurecompute/src/main/java/org/jclouds/azurecompute/domain/UpdateAffinityGroupParams.java +++ /dev/null @@ -1,84 +0,0 @@ -/* - * Licensed to the Apache Software Foundation (ASF) under one or more - * contributor license agreements. See the NOTICE file distributed with - * this work for additional information regarding copyright ownership. - * The ASF licenses this file to You 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.jclouds.azurecompute.domain; - -import com.google.auto.value.AutoValue; -import org.jclouds.javax.annotation.Nullable; - -/** - * To update an affinity group. - */ -@AutoValue -public abstract class UpdateAffinityGroupParams { - - UpdateAffinityGroupParams() { - } // For AutoValue only! - - /** - * Specifies the base-64-encoded identifier of the affinity group. - * - * @return the identifier of the affinity group - */ - @Nullable - public abstract String label(); - - /** - * Specified the description of this affinity group. - * - * @return the description of this affinity group - */ - @Nullable - public abstract String description(); - - public Builder toBuilder() { - return builder().fromUpdateAffinityGroupParams(this); - } - - public static Builder builder() { - return new Builder(); - } - - public static final class Builder { - - private String label; - - private String description; - - public Builder label(final String label) { - this.label = label; - return this; - } - - public Builder description(final String description) { - this.description = description; - return this; - } - - public UpdateAffinityGroupParams build() { - return UpdateAffinityGroupParams.create(label, description); - } - - public Builder fromUpdateAffinityGroupParams(final UpdateAffinityGroupParams in) { - return label(in.label()). - description(in.description()); - } - } - - private static UpdateAffinityGroupParams create(final String label, final String description) { - return new AutoValue_UpdateAffinityGroupParams(label, description); - } -} http://git-wip-us.apache.org/repos/asf/jclouds-labs/blob/eb990020/azurecompute/src/main/java/org/jclouds/azurecompute/domain/UpdateProfileParams.java ---------------------------------------------------------------------- diff --git a/azurecompute/src/main/java/org/jclouds/azurecompute/domain/UpdateProfileParams.java b/azurecompute/src/main/java/org/jclouds/azurecompute/domain/UpdateProfileParams.java deleted file mode 100644 index 8fc9242..0000000 --- a/azurecompute/src/main/java/org/jclouds/azurecompute/domain/UpdateProfileParams.java +++ /dev/null @@ -1,86 +0,0 @@ -/* - * Licensed to the Apache Software Foundation (ASF) under one or more - * contributor license agreements. See the NOTICE file distributed with - * this work for additional information regarding copyright ownership. - * The ASF licenses this file to You 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.jclouds.azurecompute.domain; - -import com.google.auto.value.AutoValue; -import org.jclouds.javax.annotation.Nullable; - -/** - * The Create Profile operation creates a new profile for a status version, owned by the specified subscription. - * - * @see <a href="https://msdn.microsoft.com/en-us/library/azure/hh758254.aspx">docs</a> - */ -@AutoValue -public abstract class UpdateProfileParams { - - UpdateProfileParams() { - } // For AutoValue only! - - /** - * Specifies whether the profile should be enabled or disabled. If there is a currently enabled profile, it is - * disabled. Possible values are: Enabled, Disabled; - * - * @return profile status. - */ - public abstract ProfileDefinition.Status status(); - - /** - * This element is not used. - * - * @return profile definition version. - */ - @Nullable - public abstract String version(); - - public Builder toBuilder() { - return builder().fromImageParams(this); - } - - public static Builder builder() { - return new Builder(); - } - - public static final class Builder { - - private ProfileDefinition.Status status; - private String version; - - public Builder status(final ProfileDefinition.Status status) { - this.status = status; - return this; - } - - public Builder version(final String version) { - this.version = version; - return this; - } - - public UpdateProfileParams build() { - return UpdateProfileParams.create(status, version); - } - - public Builder fromImageParams(final UpdateProfileParams in) { - return status(in.status()).version(in.version()); - } - } - - private static UpdateProfileParams create( - final ProfileDefinition.Status status, - final String version) { - return new AutoValue_UpdateProfileParams(status, version); - } -} http://git-wip-us.apache.org/repos/asf/jclouds-labs/blob/eb990020/azurecompute/src/main/java/org/jclouds/azurecompute/domain/UpdateStorageServiceParams.java ---------------------------------------------------------------------- diff --git a/azurecompute/src/main/java/org/jclouds/azurecompute/domain/UpdateStorageServiceParams.java b/azurecompute/src/main/java/org/jclouds/azurecompute/domain/UpdateStorageServiceParams.java deleted file mode 100644 index e62558d..0000000 --- a/azurecompute/src/main/java/org/jclouds/azurecompute/domain/UpdateStorageServiceParams.java +++ /dev/null @@ -1,190 +0,0 @@ -/* - * Licensed to the Apache Software Foundation (ASF) under one or more - * contributor license agreements. See the NOTICE file distributed with - * this work for additional information regarding copyright ownership. - * The ASF licenses this file to You 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.jclouds.azurecompute.domain; - -import com.google.auto.value.AutoValue; -import com.google.common.collect.ImmutableList; -import com.google.common.collect.ImmutableMap; -import java.util.List; -import java.util.Map; -import org.jclouds.javax.annotation.Nullable; - -@AutoValue -public abstract class UpdateStorageServiceParams { - - public enum AccountType { - - Standard_LRS, - Standard_GRS, - Standard_RAGRS; - - } - - /** - * Specifies information about a custom domain that is associated with the storage account. - */ - @AutoValue - public abstract static class CustomDomain { - - CustomDomain() { - } // For AutoValue only! - - /** - * Specifies the name of the custom domain. - */ - public abstract String name(); - - /** - * Indicates whether indirect CName validation is enabled. - */ - public abstract Boolean useSubDomainName(); - - public static CustomDomain create(final String name, final boolean useSubDomainName) { - return new AutoValue_UpdateStorageServiceParams_CustomDomain(name, useSubDomainName); - } - } - - UpdateStorageServiceParams() { - } // For AutoValue only! - - /** - * Specifies a base-64 encoded name for the storage account. The label may be up to 100 characters in length. The - * label can be used identify the storage account for your tracking purposes. You must specify a value for either - * Label or Description, or for both. - */ - @Nullable - public abstract String label(); - - /** - * A description for the storage account. The description may be up to 1024 characters in length. You must specify a - * value for either Label or Description, or for both. - */ - @Nullable - public abstract String description(); - - /** - * Enables or disables geo-replication on the specified the storage. If set to true, the data in the storage account - * is replicated across more than one geographic location so as to enable resilience in the face of catastrophic - * service loss. If set to false, geo-replication is disabled. If the element is not included in the request body, - * the current value is left unchanged. - */ - @Nullable - public abstract Boolean geoReplicationEnabled(); - - /** - * Represents the name of an extended cloud service property. Each extended property must have both a defined name - * and value. You can have a maximum of 50 extended property name/value pairs. - * - * <p/> - * The maximum length of the Name element is 64 characters, only alphanumeric characters and underscores are valid in - * the Name, and the name must start with a letter. Each extended property value has a maximum length of 255 - * characters. - */ - @Nullable - public abstract Map<String, String> extendedProperties(); - - /** - * Specifies the custom domains that are associated with the storage account. - */ - @Nullable - public abstract List<CustomDomain> customDomains(); - - /** - * Specifies whether the account supports locally-redundant storage, geo-redundant storage, or read access - * geo-redundant storage. Zone-redundant storage is not an option when you update a storage account. - */ - @Nullable - public abstract AccountType accountType(); - - public Builder toBuilder() { - return builder().fromUpdateStorageServiceParams(this); - } - - public static Builder builder() { - return new Builder(); - } - - public static final class Builder { - - private String label; - - private String description; - - private Boolean geoReplicationEnabled; - - private Map<String, String> extendedProperties; - - private List<CustomDomain> customDomains; - - private AccountType accountType; - - public Builder label(final String label) { - this.label = label; - return this; - } - - public Builder description(final String description) { - this.description = description; - return this; - } - - public Builder geoReplicationEnabled(final Boolean geoReplicationEnabled) { - this.geoReplicationEnabled = geoReplicationEnabled; - return this; - } - - public Builder extendedProperties(final Map<String, String> extendedProperties) { - this.extendedProperties = extendedProperties; - return this; - } - - public Builder customDomains(final List<CustomDomain> customDomains) { - this.customDomains = customDomains; - return this; - } - - public Builder accountType(final AccountType accountType) { - this.accountType = accountType; - return this; - } - - public UpdateStorageServiceParams build() { - return UpdateStorageServiceParams.create(label, description, - geoReplicationEnabled, extendedProperties, customDomains, accountType); - } - - public Builder fromUpdateStorageServiceParams(final UpdateStorageServiceParams storageServiceParams) { - return label(storageServiceParams.label()). - description(storageServiceParams.description()). - geoReplicationEnabled(storageServiceParams.geoReplicationEnabled()). - extendedProperties(storageServiceParams.extendedProperties()). - customDomains(storageServiceParams.customDomains()). - accountType(storageServiceParams.accountType()); - } - } - - private static UpdateStorageServiceParams create(final String label, final String description, - final Boolean geoReplicationEnabled, - final Map<String, String> extendedProperties, final List<CustomDomain> customDomains, - final AccountType accountType) { - - return new AutoValue_UpdateStorageServiceParams(label, description, geoReplicationEnabled, - extendedProperties == null ? null : ImmutableMap.copyOf(extendedProperties), - customDomains == null ? null : ImmutableList.copyOf(customDomains), - accountType); - } -} http://git-wip-us.apache.org/repos/asf/jclouds-labs/blob/eb990020/azurecompute/src/main/java/org/jclouds/azurecompute/domain/VMImage.java ---------------------------------------------------------------------- diff --git a/azurecompute/src/main/java/org/jclouds/azurecompute/domain/VMImage.java b/azurecompute/src/main/java/org/jclouds/azurecompute/domain/VMImage.java deleted file mode 100644 index f7f5edf..0000000 --- a/azurecompute/src/main/java/org/jclouds/azurecompute/domain/VMImage.java +++ /dev/null @@ -1,166 +0,0 @@ -/* - * Licensed to the Apache Software Foundation (ASF) under one or more - * contributor license agreements. See the NOTICE file distributed with - * this work for additional information regarding copyright ownership. - * The ASF licenses this file to You 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.jclouds.azurecompute.domain; - -import com.google.auto.value.AutoValue; -import org.jclouds.javax.annotation.Nullable; - -import java.net.URI; -import java.util.Date; -import java.util.List; - -import static com.google.common.collect.ImmutableList.copyOf; -/** - * OS image from the image repository - * - * @see <a href="https://msdn.microsoft.com/en-us/library/azure/dn499770.aspx" >api</a> - */ -@AutoValue -public abstract class VMImage { - - @AutoValue - public abstract static class OSDiskConfiguration { - - public enum Caching { - READ_ONLY, - READ_WRITE, - NONE - } - - public enum OSState { - GENERALIZED, - SPECIALIZED - } - - /** - * Specifies the name of the operating system disk. - */ - public abstract String name(); - - /** - * Specifies the caching behavior of the operating system disk. - * This setting impacts the consistency and performance of the disk. - * The default value is ReadWrite - */ - @Nullable public abstract Caching hostCaching(); - - /** - * Specifies the state of the operating system in the image. - * A Virtual Machine that is fully configured and running contains a Specialized operating system. - * A Virtual Machine on which the Sysprep command has been run with the generalize option contains - * a Generalized operating system. - */ - @Nullable public abstract OSState osState(); - - /** - * Specifies the operating system type of the image. - */ - public abstract OSImage.Type os(); - - /** - * Specifies the location of the blob in Azure storage. The blob location belongs to a storage account in the - * subscription specified by the <subscription-id> value in the operation call. - */ - @Nullable public abstract URI mediaLink(); - - /** - * Specifies the size, in GB, of the operating system disk - */ - @Nullable public abstract Integer logicalSizeInGB(); - - /** - * This property identifies the type of the storage account for the backing VHD. - */ - @Nullable public abstract String ioType(); - - public static OSDiskConfiguration create(String name, Caching hostCaching, OSState osState, OSImage.Type os, - URI mediaLink, Integer logicalDiskSizeInGB, String ioType) { - return new AutoValue_VMImage_OSDiskConfiguration(name, hostCaching, osState, os, mediaLink, - logicalDiskSizeInGB, ioType); - } - - } - - public abstract String name(); - - /** - * The name can be up to 100 characters in length. The name can be used identify the storage account for your - * tracking purposes. - */ - public abstract String label(); - - /** - * The repository classification of image. All user images have the category "User", but - * categories for other images could be, for example "Canonical" - */ - @Nullable public abstract String category(); - - @Nullable public abstract String description(); - - @Nullable public abstract OSDiskConfiguration osDiskConfiguration(); - - public abstract List<DataVirtualHardDisk> dataDiskConfiguration(); - - @Nullable public abstract String serviceName(); - - @Nullable public abstract String deploymentName(); - - @Nullable public abstract String roleName(); - - /** - * The geo-locations of the image, if the image is not associated with an affinity group. - */ - @Nullable public abstract String location(); - - /** - * The affinity group with which this image is associated, if any. - */ - @Nullable public abstract String affinityGroup(); - - @Nullable public abstract Date createdTime(); - - @Nullable public abstract Date modifiedTime(); - - @Nullable public abstract String language(); - - @Nullable public abstract String imageFamily(); - - @Nullable public abstract RoleSize.Type recommendedVMSize(); - - @Nullable public abstract Boolean isPremium(); - - @Nullable public abstract String eula(); - - @Nullable public abstract URI iconUri(); - - @Nullable public abstract URI smallIconUri(); - - @Nullable public abstract URI privacyUri(); - - @Nullable public abstract Date publishedDate(); - - public static VMImage create(String name, String label, String category, String description, - OSDiskConfiguration osDiskConfiguration, List<DataVirtualHardDisk> dataDiskConfiguration, String serviceName, - String deploymentName, String roleName, String location, String affinityGroup, Date createdTime, - Date modifiedTime, String language, String imageFamily, RoleSize.Type recommendedVMSize, Boolean isPremium, - String eula, URI iconUri, URI smallIconUri, - URI privacyUri, Date publishedDate) { - return new AutoValue_VMImage(name, label, category, description, osDiskConfiguration, copyOf(dataDiskConfiguration), - serviceName, deploymentName, roleName, location, affinityGroup, createdTime, modifiedTime, language, - imageFamily, recommendedVMSize, isPremium, eula, iconUri, smallIconUri, privacyUri, publishedDate); - } -} http://git-wip-us.apache.org/repos/asf/jclouds-labs/blob/eb990020/azurecompute/src/main/java/org/jclouds/azurecompute/domain/VMImageParams.java ---------------------------------------------------------------------- diff --git a/azurecompute/src/main/java/org/jclouds/azurecompute/domain/VMImageParams.java b/azurecompute/src/main/java/org/jclouds/azurecompute/domain/VMImageParams.java deleted file mode 100644 index 7fda79d..0000000 --- a/azurecompute/src/main/java/org/jclouds/azurecompute/domain/VMImageParams.java +++ /dev/null @@ -1,246 +0,0 @@ -/* - * Licensed to the Apache Software Foundation (ASF) under one or more - * contributor license agreements. See the NOTICE file distributed with - * this work for additional information regarding copyright ownership. - * The ASF licenses this file to You 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.jclouds.azurecompute.domain; - -import com.google.auto.value.AutoValue; -import com.google.common.collect.Lists; -import org.jclouds.javax.annotation.Nullable; - -import java.net.URI; -import java.util.Collection; -import java.util.List; - -/** - * OS image from the image repository - * - * @see <a href="https://msdn.microsoft.com/en-us/library/azure/dn499770.aspx" >api</a> - */ -@AutoValue -public abstract class VMImageParams { - - @AutoValue - public abstract static class OSDiskConfigurationParams { - - public enum Caching { - READ_ONLY, - READ_WRITE, - NONE - } - - public enum OSState { - GENERALIZED, - SPECIALIZED - } - - /** - * Specifies the name of the operating system disk. - */ - @Nullable public abstract String name(); - - /** - * Specifies the caching behavior of the operating system disk. - * This setting impacts the consistency and performance of the disk. - * The default value is ReadWrite - */ - @Nullable public abstract Caching hostCaching(); - - /** - * Specifies the state of the operating system in the image. - * A Virtual Machine that is fully configured and running contains a Specialized operating system. - * A Virtual Machine on which the Sysprep command has been run with the generalize option contains - * a Generalized operating system. - */ - - @Nullable public abstract OSState osState(); - - /** - * Specifies the operating system type of the image. - */ - public abstract OSImage.Type os(); - - /** - * Specifies the location of the blob in Azure storage. The blob location belongs to a storage account in the - * subscription specified by the <subscription-id> value in the operation call. - */ - @Nullable public abstract URI mediaLink(); - - /** - * Specifies the size, in GB, of the operating system disk - */ - @Nullable public abstract Integer logicalSizeInGB(); - - /** - * This property identifies the type of the storage account for the backing VHD. - */ - @Nullable public abstract String ioType(); - - public static OSDiskConfigurationParams OSDiskConfiguration(String name, Caching hostCaching, OSState osState, - OSImage.Type os, URI mediaLink, Integer logicalDiskSizeInGB, String ioType) { - return new AutoValue_VMImageParams_OSDiskConfigurationParams(name, hostCaching, osState, os, mediaLink, - logicalDiskSizeInGB, ioType); - } - - } - - @Nullable public abstract String name(); - - /** - * The name can be up to 100 characters in length. The name can be used identify the storage account for your - * tracking purposes. - */ - @Nullable public abstract String label(); - - @Nullable public abstract String description(); - - @Nullable public abstract OSDiskConfigurationParams osDiskConfiguration(); - - public abstract List<DataVirtualHardDisk> dataDiskConfiguration(); - - @Nullable public abstract String language(); - - @Nullable public abstract String imageFamily(); - - @Nullable public abstract RoleSize.Type recommendedVMSize(); - - @Nullable public abstract String eula(); - - @Nullable public abstract URI iconUri(); - - @Nullable public abstract URI smallIconUri(); - - @Nullable public abstract URI privacyUri(); - - @Nullable public abstract Boolean showGui(); - - public Builder toBuilder() { - return builder().fromVMImageParams(this); - } - - public static Builder builder() { - return new Builder(); - } - - public static final class Builder { - private String name; - private String label; - private String description; - private OSDiskConfigurationParams osDiskConfiguration; - private List<DataVirtualHardDisk> dataDiskConfiguration = Lists.newArrayList(); - private String language; - private String imageFamily; - private RoleSize.Type recommendedVMSize; - private String eula; - private URI iconUri; - private URI smallIconUri; - private URI privacyUri; - private Boolean showGui; - - public Builder name(String name) { - this.name = name; - return this; - } - - public Builder label(String label) { - this.label = label; - return this; - } - - public Builder description(String description) { - this.description = description; - return this; - } - - public Builder osDiskConfiguration(OSDiskConfigurationParams osDiskConfig) { - this.osDiskConfiguration = osDiskConfig; - return this; - } - - public Builder language(String language) { - this.language = language; - return this; - } - - public Builder imageFamily(String imageFamily) { - this.imageFamily = imageFamily; - return this; - } - - public Builder recommendedVMSize(RoleSize.Type recommendedRoleSize) { - this.recommendedVMSize = recommendedRoleSize; - return this; - } - - public Builder showGui(Boolean showGui) { - this.showGui = showGui; - return this; - } - - public Builder eula(String eula) { - this.eula = eula; - return this; - } - - public Builder iconUri(URI iconUri) { - this.iconUri = iconUri; - return this; - } - - public Builder smallIconUri(URI smallIconUri) { - this.smallIconUri = smallIconUri; - return this; - } - - public Builder privacyUri(URI privacyUri) { - this.privacyUri = smallIconUri; - return this; - } - - public Builder dataDiskConfiguration(DataVirtualHardDisk dataDiskConfiguration) { - this.dataDiskConfiguration.add(dataDiskConfiguration); - return this; - } - - public Builder dataDiskConfigurations(Collection<DataVirtualHardDisk> dataDiskConfiguration) { - this.dataDiskConfiguration.addAll(dataDiskConfiguration); - return this; - } - - public VMImageParams build() { - return VMImageParams - .create(name, label, description, osDiskConfiguration, dataDiskConfiguration, language, - imageFamily, recommendedVMSize, eula, iconUri, smallIconUri, privacyUri, - showGui); - } - - public Builder fromVMImageParams(VMImageParams in) { - return name(in.name()).label(in.label()).description(in.description()) - .osDiskConfiguration(in.osDiskConfiguration()).dataDiskConfigurations(in.dataDiskConfiguration()) - .language(in.language()).imageFamily(in.imageFamily()).recommendedVMSize(in.recommendedVMSize()) - .eula(in.eula()).iconUri(in.iconUri()).smallIconUri(in.smallIconUri()).privacyUri(in.privacyUri()); - } - - } - - public static VMImageParams create(String name, String label, String description, - OSDiskConfigurationParams osDiskConfiguration, List<DataVirtualHardDisk> dataDiskConfiguration, - String language, String imageFamily, RoleSize.Type recommendedVMSize, String eula, URI iconUri, - URI smallIconUri, URI privacyUri, Boolean showGui) { - return new AutoValue_VMImageParams(name, label, description, osDiskConfiguration, dataDiskConfiguration, - language, imageFamily, recommendedVMSize, eula, iconUri, smallIconUri, privacyUri, - showGui); - } -} http://git-wip-us.apache.org/repos/asf/jclouds-labs/blob/eb990020/azurecompute/src/main/java/org/jclouds/azurecompute/features/AffinityGroupApi.java ---------------------------------------------------------------------- diff --git a/azurecompute/src/main/java/org/jclouds/azurecompute/features/AffinityGroupApi.java b/azurecompute/src/main/java/org/jclouds/azurecompute/features/AffinityGroupApi.java deleted file mode 100644 index cb11df0..0000000 --- a/azurecompute/src/main/java/org/jclouds/azurecompute/features/AffinityGroupApi.java +++ /dev/null @@ -1,122 +0,0 @@ -/* - * Licensed to the Apache Software Foundation (ASF) under one or more - * contributor license agreements. See the NOTICE file distributed with - * this work for additional information regarding copyright ownership. - * The ASF licenses this file to You 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.jclouds.azurecompute.features; - -import static javax.ws.rs.core.MediaType.APPLICATION_XML; - -import java.util.List; - -import javax.inject.Named; -import javax.ws.rs.Consumes; -import javax.ws.rs.DELETE; -import javax.ws.rs.GET; -import javax.ws.rs.POST; -import javax.ws.rs.PUT; -import javax.ws.rs.Path; -import javax.ws.rs.PathParam; -import javax.ws.rs.Produces; - -import org.jclouds.Fallbacks.EmptyListOnNotFoundOr404; -import org.jclouds.Fallbacks.NullOnNotFoundOr404; -import org.jclouds.azurecompute.binders.CreateAffinityGroupParamsToXML; -import org.jclouds.azurecompute.binders.UpdateAffinityGroupParamsToXML; -import org.jclouds.azurecompute.domain.AffinityGroup; -import org.jclouds.azurecompute.domain.CreateAffinityGroupParams; -import org.jclouds.azurecompute.domain.UpdateAffinityGroupParams; -import org.jclouds.azurecompute.functions.ParseRequestIdHeader; -import org.jclouds.azurecompute.xml.AffinityGroupHandler; -import org.jclouds.azurecompute.xml.ListAffinityGroupsHandler; -import org.jclouds.rest.annotations.BinderParam; -import org.jclouds.rest.annotations.Fallback; -import org.jclouds.rest.annotations.Headers; -import org.jclouds.rest.annotations.ResponseParser; -import org.jclouds.rest.annotations.XMLResponseParser; - -/** - * The Service Management API includes operations for managing affinity groups in your subscription. - * - * @see <a href="http://msdn.microsoft.com/en-us/library/azure/ee460798">docs</a> - */ -@Path("/affinitygroups") -@Headers(keys = "x-ms-version", values = "{jclouds.api-version}") -@Consumes(APPLICATION_XML) -@Produces(APPLICATION_XML) -public interface AffinityGroupApi { - - /** - * The List Affinity Groups operation lists the affinity groups that are associated with the specified subscription. - * - * @return the affinity groups that are associated with the specified subscription - */ - @Named("ListAffinityGroups") - @GET - @XMLResponseParser(ListAffinityGroupsHandler.class) - @Fallback(EmptyListOnNotFoundOr404.class) - List<AffinityGroup> list(); - - /** - * The Get Affinity Group Properties operation returns the system properties that are associated with the specified - * affinity group. - * - * @param name name of the affinity group - * @return the system properties that are associated with the specified affinity group - */ - @Named("GetAffinityGroup") - @GET - @Path("/{name}") - @XMLResponseParser(AffinityGroupHandler.class) - @Fallback(NullOnNotFoundOr404.class) - AffinityGroup get(@PathParam("name") String name); - - /** - * The Create Affinity Group operation creates a new affinity group for the specified subscription. - * - * @param params the affinity group to be created - * @return a value that uniquely identifies a request made against the management service - */ - @Named("AddAffinityGroup") - @POST - @ResponseParser(ParseRequestIdHeader.class) - String add(@BinderParam(CreateAffinityGroupParamsToXML.class) CreateAffinityGroupParams params); - - /** - * The Update Affinity Group operation updates the label or the description for an affinity group in the specified - * subscription. - * - * @param params the affinity group to be created - * @return a value that uniquely identifies a request made against the management service - */ - @Named("UpdateAffinityGroup") - @PUT - @Path("/{name}") - @ResponseParser(ParseRequestIdHeader.class) - String update(@PathParam("name") String name, - @BinderParam(UpdateAffinityGroupParamsToXML.class) UpdateAffinityGroupParams params); - - /** - * The Delete Affinity Group operation deletes an affinity group in the specified subscription. - * - * @param name name of the affinity group - * @return a value that uniquely identifies a request made against the management service - */ - @Named("DeleteAffinityGroup") - @DELETE - @Path("/{name}") - @Fallback(NullOnNotFoundOr404.class) - @ResponseParser(ParseRequestIdHeader.class) - String delete(@PathParam("name") String name); -} http://git-wip-us.apache.org/repos/asf/jclouds-labs/blob/eb990020/azurecompute/src/main/java/org/jclouds/azurecompute/features/CloudServiceApi.java ---------------------------------------------------------------------- diff --git a/azurecompute/src/main/java/org/jclouds/azurecompute/features/CloudServiceApi.java b/azurecompute/src/main/java/org/jclouds/azurecompute/features/CloudServiceApi.java deleted file mode 100644 index 5a3b1ca..0000000 --- a/azurecompute/src/main/java/org/jclouds/azurecompute/features/CloudServiceApi.java +++ /dev/null @@ -1,151 +0,0 @@ -/* - * Licensed to the Apache Software Foundation (ASF) under one or more - * contributor license agreements. See the NOTICE file distributed with - * this work for additional information regarding copyright ownership. - * The ASF licenses this file to You 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.jclouds.azurecompute.features; - -import static javax.ws.rs.core.MediaType.APPLICATION_XML; - -import java.util.List; - -import javax.inject.Named; -import javax.ws.rs.Consumes; -import javax.ws.rs.DELETE; -import javax.ws.rs.GET; -import javax.ws.rs.POST; -import javax.ws.rs.Path; -import javax.ws.rs.PathParam; -import javax.ws.rs.Produces; - -import org.jclouds.Fallbacks.EmptyListOnNotFoundOr404; -import org.jclouds.Fallbacks.NullOnNotFoundOr404; -import org.jclouds.azurecompute.domain.CloudService; -import org.jclouds.azurecompute.domain.CloudServiceProperties; -import org.jclouds.azurecompute.functions.Base64EncodeLabel; -import org.jclouds.azurecompute.functions.ParseRequestIdHeader; -import org.jclouds.azurecompute.xml.CloudServiceHandler; -import org.jclouds.azurecompute.xml.CloudServicePropertiesHandler; -import org.jclouds.azurecompute.xml.ListCloudServicesHandler; -import org.jclouds.javax.annotation.Nullable; -import org.jclouds.rest.annotations.Fallback; -import org.jclouds.rest.annotations.Headers; -import org.jclouds.rest.annotations.ParamParser; -import org.jclouds.rest.annotations.Payload; -import org.jclouds.rest.annotations.PayloadParam; -import org.jclouds.rest.annotations.QueryParams; -import org.jclouds.rest.annotations.ResponseParser; -import org.jclouds.rest.annotations.XMLResponseParser; - -/** - * The Service Management API includes operations for managing the cloud services beneath your subscription. - * - * @see <a href="http://msdn.microsoft.com/en-us/library/ee460812">docs</a> - */ -@Path("/services/hostedservices") -@Headers(keys = "x-ms-version", values = "{jclouds.api-version}") -@Consumes(APPLICATION_XML) -public interface CloudServiceApi { - - /** - * The List Cloud Services operation lists the cloud services available under the current subscription. - * - * @return the response object - */ - @Named("ListCloudServices") - @GET - @QueryParams(keys = "embed-detail", values = "true") - @XMLResponseParser(ListCloudServicesHandler.class) - @Fallback(EmptyListOnNotFoundOr404.class) - List<CloudService> list(); - - /** - * The Create Cloud Service operation creates a new cloud service in Windows Azure. - * - * @param name A name for the cloud service that is unique within Windows Azure. This name is the DNS prefix name and - * can be used to access the cloud service. - * - * For example: http://name.cloudapp.net// - * @param label The name can be used identify the storage account for your tracking purposes. The name can be up to - * 100 characters in length. - * @param location The location where the cloud service will be created. - * @return the requestId to track this async request progress - * - * @see <a href="http://msdn.microsoft.com/en-us/library/ee460812">docs</a> - */ - @Named("CreateCloudService") - @POST - @Produces(APPLICATION_XML) - @ResponseParser(ParseRequestIdHeader.class) - @Payload("<CreateHostedService xmlns=\"http://schemas.microsoft.com/windowsazure\">" - + "<ServiceName>{name}</ServiceName><Label>{label}</Label>" - + "<Location>{location}</Location></CreateHostedService>") - String createWithLabelInLocation(@PayloadParam("name") String name, - @PayloadParam("label") @ParamParser(Base64EncodeLabel.class) String label, - @PayloadParam("location") String location); - - /** - * The Get Cloud Service Properties operation retrieves system properties for the specified cloud service. These - * properties include the service name and service type; the name of the affinity group to which the service belongs, - * or its location if it is not part of an affinity group. - * - * @param name the unique DNS Prefix value in the Windows Azure Management Portal - */ - @Named("GetCloudServiceProperties") - @GET - @Path("/{name}") - @QueryParams(keys = "embed-detail", values = "true") - @XMLResponseParser(CloudServiceHandler.class) - @Fallback(NullOnNotFoundOr404.class) - @Nullable - CloudService get(@PathParam("name") String name); - - /** - * The Delete Cloud Service operation deletes the specified cloud service from Windows Azure. - * - * @param name the unique DNS Prefix value in the Windows Azure Management Portal - * - * @return request id or null, if not found - */ - @Named("DeleteCloudService") - @DELETE - @Path("/{name}") - @Fallback(NullOnNotFoundOr404.class) - @ResponseParser(ParseRequestIdHeader.class) - String delete(@PathParam("name") String name); - - /* - * The Get Cloud Service Properties operation retrieves properties for the specified cloud service. - * - * These properties include the following values: - * The name and the description of the cloud service. - * - * The name of the affinity group to which the cloud service belongs, or its location if it is not part of an affinity group. - * - * The label that can be used to track the cloud service. - * - * The date and time that the cloud service was created or modified. - * - * If details are requested, information about deployments in the cloud service is returned. - * - * */ - - @Named("CloudServiceProperties") - @GET - @Path("/{name}") - @QueryParams(keys = "embed-detail", values = "true") - @XMLResponseParser(CloudServicePropertiesHandler.class) - @Fallback(NullOnNotFoundOr404.class) - @Nullable CloudServiceProperties getProperties(@PathParam("name") String name); -} http://git-wip-us.apache.org/repos/asf/jclouds-labs/blob/eb990020/azurecompute/src/main/java/org/jclouds/azurecompute/features/DeploymentApi.java ---------------------------------------------------------------------- diff --git a/azurecompute/src/main/java/org/jclouds/azurecompute/features/DeploymentApi.java b/azurecompute/src/main/java/org/jclouds/azurecompute/features/DeploymentApi.java deleted file mode 100644 index b7afcf8..0000000 --- a/azurecompute/src/main/java/org/jclouds/azurecompute/features/DeploymentApi.java +++ /dev/null @@ -1,76 +0,0 @@ -/* - * Licensed to the Apache Software Foundation (ASF) under one or more - * contributor license agreements. See the NOTICE file distributed with - * this work for additional information regarding copyright ownership. - * The ASF licenses this file to You 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.jclouds.azurecompute.features; - -import javax.inject.Named; -import javax.ws.rs.Consumes; -import javax.ws.rs.DELETE; -import javax.ws.rs.GET; -import javax.ws.rs.POST; -import javax.ws.rs.Path; -import javax.ws.rs.PathParam; -import javax.ws.rs.Produces; -import javax.ws.rs.core.MediaType; - -import org.jclouds.Fallbacks.NullOnNotFoundOr404; -import org.jclouds.azurecompute.binders.DeploymentParamsToXML; -import org.jclouds.azurecompute.domain.Deployment; -import org.jclouds.azurecompute.domain.DeploymentParams; -import org.jclouds.azurecompute.functions.ParseRequestIdHeader; -import org.jclouds.azurecompute.xml.DeploymentHandler; -import org.jclouds.rest.annotations.BinderParam; -import org.jclouds.rest.annotations.Fallback; -import org.jclouds.rest.annotations.Headers; -import org.jclouds.rest.annotations.ResponseParser; -import org.jclouds.rest.annotations.XMLResponseParser; - -@Path("/services/hostedservices/{serviceName}/deployments") -@Headers(keys = "x-ms-version", values = "{jclouds.api-version}") -@Consumes(MediaType.APPLICATION_XML) -public interface DeploymentApi { - - /** - * The Get Deployment operation returns the specified deployment from Windows Azure. - * - * @param name the unique DNS Prefix value in the Windows Azure Management Portal - */ - @Named("GetDeployment") - @GET - @Path("/{name}") - @XMLResponseParser(DeploymentHandler.class) - @Fallback(NullOnNotFoundOr404.class) - Deployment get(@PathParam("name") String name); - - @Named("CreateVirtualMachineDeployment") - @POST - @Produces(MediaType.APPLICATION_XML) - @ResponseParser(ParseRequestIdHeader.class) - String create(@BinderParam(DeploymentParamsToXML.class) DeploymentParams params); - - /** - * The Delete Deployment operation deletes the specified deployment from Windows Azure. - * - * @param name the unique DNS Prefix value in the Windows Azure Management Portal - */ - @Named("DeleteDeployment") - @DELETE - @Path("/{name}") - @Fallback(NullOnNotFoundOr404.class) - @ResponseParser(ParseRequestIdHeader.class) - String delete(@PathParam("name") String name); - -}
