Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
@@ -0,0 +1,41 @@
/**
* Copyright (c) Microsoft Corporation. All rights reserved.
* Licensed under the MIT License. See License.txt in the project root for
* license information.
*
* Code generated by Microsoft (R) AutoRest Code Generator.
*/

package com.microsoft.azure.management.containerregistry;

import java.util.Collection;
import com.fasterxml.jackson.annotation.JsonCreator;
import com.microsoft.rest.ExpandableStringEnum;

/**
* Defines values for ImportMode.
*/
public final class ImportMode extends ExpandableStringEnum<ImportMode> {
/** Static value NoForce for ImportMode. */
public static final ImportMode NO_FORCE = fromString("NoForce");

/** Static value Force for ImportMode. */
public static final ImportMode FORCE = fromString("Force");

/**
* Creates or finds a ImportMode from its string representation.
* @param name a name to look for
* @return the corresponding ImportMode
*/
@JsonCreator
public static ImportMode fromString(String name) {
return fromString(name, ImportMode.class);
}

/**
* @return known ImportMode values
*/
public static Collection<ImportMode> values() {
return values(ImportMode.class);
}
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,74 @@
/**
* Copyright (c) Microsoft Corporation. All rights reserved.
* Licensed under the MIT License. See License.txt in the project root for
* license information.
*
* Code generated by Microsoft (R) AutoRest Code Generator.
*/

package com.microsoft.azure.management.containerregistry;

import com.fasterxml.jackson.annotation.JsonProperty;

/**
* The ImportSource model.
*/
public class ImportSource {
/**
* The resource identifier of the target Azure Container Registry.
*/
@JsonProperty(value = "resourceId", required = true)
private String resourceId;

/**
* Repository name of the source image.
* Specify an image by repository ('hello-world'). This will use the
* 'latest' tag.
* Specify an image by tag ('hello-world:latest').
* Specify an image by sha256-based manifest digest
* ('hello-world@sha256:abc123').
*/
@JsonProperty(value = "sourceImage", required = true)
private String sourceImage;

/**
* Get the resourceId value.
*
* @return the resourceId value
*/
public String resourceId() {
return this.resourceId;
}

/**
* Set the resourceId value.
*
* @param resourceId the resourceId value to set
* @return the ImportSource object itself.
*/
public ImportSource withResourceId(String resourceId) {
this.resourceId = resourceId;
return this;
}

/**
* Get the sourceImage value.
*
* @return the sourceImage value
*/
public String sourceImage() {
return this.sourceImage;
}

/**
* Set the sourceImage value.
*
* @param sourceImage the sourceImage value to set
* @return the ImportSource object itself.
*/
public ImportSource withSourceImage(String sourceImage) {
this.sourceImage = sourceImage;
return this;
}

}
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,7 @@ public class Target {

/**
* The digest of the content, as defined by the Registry V2 HTTP API
* Specificiation.
* Specification.
*/
@JsonProperty(value = "digest")
private String digest;
Expand Down
Original file line number Diff line number Diff line change
@@ -0,0 +1,206 @@
/**
* Copyright (c) Microsoft Corporation. All rights reserved.
* Licensed under the MIT License. See License.txt in the project root for
* license information.
*
* Code generated by Microsoft (R) AutoRest Code Generator.
*/

package com.microsoft.azure.management.containerregistry.implementation;

import java.util.List;
import com.fasterxml.jackson.annotation.JsonProperty;

/**
* The ImageCopyFromModelInner model.
*/
public class ImageCopyFromModelInner {
/**
* Repository name of the source image.
*/
@JsonProperty(value = "sourceRepository", required = true)
private String sourceRepository;

/**
* The tag name of the source image. When both source tag and source
* manifest are omitted the 'latest' tag will be used.
* Exclusive with SourceManifestDigest.
*/
@JsonProperty(value = "sourceTag")
private String sourceTag;

/**
* The manifest sha of the source image. Exclusive with SourceTag.
*/
@JsonProperty(value = "sourceManifestDigest")
private String sourceManifestDigest;

/**
* The resource id of the source registry.
*/
@JsonProperty(value = "sourceRegistryResourceId", required = true)
private String sourceRegistryResourceId;

/**
* List of strings of the form repo[:tag]. When tag is omitted the source
* will be used (or 'latest' if source tag is also omitted.).
*/
@JsonProperty(value = "targetTags")
private List<String> targetTags;

/**
* List of strings of repository names to do a manifest only copy. No tag
* will be created.
*/
@JsonProperty(value = "untaggedTargetRepositories")
private List<String> untaggedTargetRepositories;

/**
* When true, any existing target tags will be overwritten. When false,
* any existing target tags will fail the operation before any copying
* begins.
*/
@JsonProperty(value = "force")
private Boolean force;

/**
* Get the sourceRepository value.
*
* @return the sourceRepository value
*/
public String sourceRepository() {
return this.sourceRepository;
}

/**
* Set the sourceRepository value.
*
* @param sourceRepository the sourceRepository value to set
* @return the ImageCopyFromModelInner object itself.
*/
public ImageCopyFromModelInner withSourceRepository(String sourceRepository) {
this.sourceRepository = sourceRepository;
return this;
}

/**
* Get the sourceTag value.
*
* @return the sourceTag value
*/
public String sourceTag() {
return this.sourceTag;
}

/**
* Set the sourceTag value.
*
* @param sourceTag the sourceTag value to set
* @return the ImageCopyFromModelInner object itself.
*/
public ImageCopyFromModelInner withSourceTag(String sourceTag) {
this.sourceTag = sourceTag;
return this;
}

/**
* Get the sourceManifestDigest value.
*
* @return the sourceManifestDigest value
*/
public String sourceManifestDigest() {
return this.sourceManifestDigest;
}

/**
* Set the sourceManifestDigest value.
*
* @param sourceManifestDigest the sourceManifestDigest value to set
* @return the ImageCopyFromModelInner object itself.
*/
public ImageCopyFromModelInner withSourceManifestDigest(String sourceManifestDigest) {
this.sourceManifestDigest = sourceManifestDigest;
return this;
}

/**
* Get the sourceRegistryResourceId value.
*
* @return the sourceRegistryResourceId value
*/
public String sourceRegistryResourceId() {
return this.sourceRegistryResourceId;
}

/**
* Set the sourceRegistryResourceId value.
*
* @param sourceRegistryResourceId the sourceRegistryResourceId value to set
* @return the ImageCopyFromModelInner object itself.
*/
public ImageCopyFromModelInner withSourceRegistryResourceId(String sourceRegistryResourceId) {
this.sourceRegistryResourceId = sourceRegistryResourceId;
return this;
}

/**
* Get the targetTags value.
*
* @return the targetTags value
*/
public List<String> targetTags() {
return this.targetTags;
}

/**
* Set the targetTags value.
*
* @param targetTags the targetTags value to set
* @return the ImageCopyFromModelInner object itself.
*/
public ImageCopyFromModelInner withTargetTags(List<String> targetTags) {
this.targetTags = targetTags;
return this;
}

/**
* Get the untaggedTargetRepositories value.
*
* @return the untaggedTargetRepositories value
*/
public List<String> untaggedTargetRepositories() {
return this.untaggedTargetRepositories;
}

/**
* Set the untaggedTargetRepositories value.
*
* @param untaggedTargetRepositories the untaggedTargetRepositories value to set
* @return the ImageCopyFromModelInner object itself.
*/
public ImageCopyFromModelInner withUntaggedTargetRepositories(List<String> untaggedTargetRepositories) {
this.untaggedTargetRepositories = untaggedTargetRepositories;
return this;
}

/**
* Get the force value.
*
* @return the force value
*/
public Boolean force() {
return this.force;
}

/**
* Set the force value.
*
* @param force the force value to set
* @return the ImageCopyFromModelInner object itself.
*/
public ImageCopyFromModelInner withForce(Boolean force) {
this.force = force;
return this;
}

}
Loading