Skip to content

Commit

Permalink
Merge pull request Azure#1143 from anuchandy/compute-annot
Browse files Browse the repository at this point in the history
renaming image() -> getImage() as it make REST call and removing unne…
  • Loading branch information
Martin Sawicki authored Sep 30, 2016
2 parents 8e9beec + 1ea35a0 commit 351c20b
Show file tree
Hide file tree
Showing 6 changed files with 5 additions and 8 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -33,5 +33,5 @@ public interface VirtualMachineExtensionImageVersion extends
/**
* @return virtual machine extension image this version represents
*/
VirtualMachineExtensionImage image();
VirtualMachineExtensionImage getImage();
}
Original file line number Diff line number Diff line change
@@ -1,11 +1,8 @@
package com.microsoft.azure.management.compute;

import com.microsoft.azure.management.apigeneration.LangDefinition;

/**
* Scale set virtual machine sku types.
*/
@LangDefinition
public class VirtualMachineScaleSetSkuTypes {
/** Static value Standard_A0 for VirtualMachineScaleSetSkuTypes. */
public static final VirtualMachineScaleSetSkuTypes STANDARD_A0 = new VirtualMachineScaleSetSkuTypes("Standard_A0", "Standard");
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -43,7 +43,7 @@ public VirtualMachineExtensionImageType type() {
}

@Override
public VirtualMachineExtensionImage image() {
public VirtualMachineExtensionImage getImage() {
VirtualMachineExtensionImageInner inner = this.client.get(this.regionName(),
this.type().publisher().name(),
this.type().name(),
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -50,7 +50,7 @@ public PagedList<VirtualMachineExtensionImageVersion> loadList(VirtualMachineExt
new PagedListConverter<VirtualMachineExtensionImageVersion, VirtualMachineExtensionImage>() {
@Override
public VirtualMachineExtensionImage typeConvert(VirtualMachineExtensionImageVersion virtualMachineExtensionImageVersion) {
return virtualMachineExtensionImageVersion.image();
return virtualMachineExtensionImageVersion.getImage();
}
};

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -104,7 +104,7 @@ public void canGetExtensionTypeVersionAndImage() throws Exception {

// Fetch the Azure docker extension image
//
VirtualMachineExtensionImage dockerExtensionImage = extensionImageFirstVersion.image();
VirtualMachineExtensionImage dockerExtensionImage = extensionImageFirstVersion.getImage();

Assert.assertTrue(dockerExtensionImage.regionName().equalsIgnoreCase(Region.US_EAST.toString()));
Assert.assertTrue(dockerExtensionImage.publisherName().equalsIgnoreCase(dockerExtensionPublisherName));
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -72,7 +72,7 @@ public static void main(String[] args) {

for (VirtualMachineExtensionImageType imageType : chosenPublisher.extensionTypes().list()) {
for (VirtualMachineExtensionImageVersion version: imageType.versions().list()) {
VirtualMachineExtensionImage image = version.image();
VirtualMachineExtensionImage image = version.getImage();
System.out.println("Image - " + chosenPublisher.name() + "/"
+ image.typeName() + "/"
+ image.versionName());
Expand Down

0 comments on commit 351c20b

Please sign in to comment.