@Override public int hashCode() { final int prime = 31; int hashCode = 1; hashCode = prime * hashCode + ((getRegistryId() == null) ? 0 : getRegistryId().hashCode()); hashCode = prime * hashCode + ((getRepositoryName() == null) ? 0 : getRepositoryName().hashCode()); hashCode = prime * hashCode + ((getImageDigest() == null) ? 0 : getImageDigest().hashCode()); hashCode = prime * hashCode + ((getImageTags() == null) ? 0 : getImageTags().hashCode()); hashCode = prime * hashCode + ((getImageSizeInBytes() == null) ? 0 : getImageSizeInBytes().hashCode()); hashCode = prime * hashCode + ((getImagePushedAt() == null) ? 0 : getImagePushedAt().hashCode()); return hashCode; }
/** * <p> * The <code>sha256</code> digest of the image manifest. * </p> * * @param imageDigest * The <code>sha256</code> digest of the image manifest. * @return Returns a reference to this object so that method calls can be chained together. */ public ImageDetail withImageDigest(String imageDigest) { setImageDigest(imageDigest); return this; }
/** * <p> * The date and time, expressed in standard JavaScript date format, at which the current image was pushed to the * repository. * </p> * * @param imagePushedAt * The date and time, expressed in standard JavaScript date format, at which the current image was pushed to * the repository. * @return Returns a reference to this object so that method calls can be chained together. */ public ImageDetail withImagePushedAt(java.util.Date imagePushedAt) { setImagePushedAt(imagePushedAt); return this; }
for(ImageDetail imageDetail : imageList) Date pushedAt = imageDetail.getImagePushedAt(); Long pushTime = null; if(pushedAt != null) pushTime = pushedAt.getTime(); String imageSha = imageDetail.getImageDigest().toLowerCase(); List<String> imageTags = imageDetail.getImageTags(); DockerImage.DockerImageBuilder builder = DockerImage .builder() .imageSha(imageSha) .pushTime(pushTime) .imageSize(imageDetail.getImageSizeInBytes());
public ImageDetail unmarshall(JsonUnmarshallerContext context) throws Exception { ImageDetail imageDetail = new ImageDetail(); if (context.testExpression("registryId", targetDepth)) { context.nextToken(); imageDetail.setRegistryId(context.getUnmarshaller(String.class).unmarshall(context)); imageDetail.setRepositoryName(context.getUnmarshaller(String.class).unmarshall(context)); imageDetail.setImageDigest(context.getUnmarshaller(String.class).unmarshall(context)); imageDetail.setImageTags(new ListUnmarshaller<String>(context.getUnmarshaller(String.class)).unmarshall(context)); imageDetail.setImageSizeInBytes(context.getUnmarshaller(Long.class).unmarshall(context)); imageDetail.setImagePushedAt(DateJsonUnmarshallerFactory.getInstance("unixTimestamp").unmarshall(context));
/** * <p> * The size, in bytes, of the image in the repository. * </p> * <note> * <p> * Beginning with Docker version 1.9, the Docker client compresses image layers before pushing them to a V2 Docker * registry. The output of the <code>docker images</code> command shows the uncompressed image size, so it may * return a larger image size than the image sizes returned by <a>DescribeImages</a>. * </p> * </note> * * @param imageSizeInBytes * The size, in bytes, of the image in the repository.</p> <note> * <p> * Beginning with Docker version 1.9, the Docker client compresses image layers before pushing them to a V2 * Docker registry. The output of the <code>docker images</code> command shows the uncompressed image size, * so it may return a larger image size than the image sizes returned by <a>DescribeImages</a>. * </p> * @return Returns a reference to this object so that method calls can be chained together. */ public ImageDetail withImageSizeInBytes(Long imageSizeInBytes) { setImageSizeInBytes(imageSizeInBytes); return this; }
public ImageDetail unmarshall(JsonUnmarshallerContext context) throws Exception { ImageDetail imageDetail = new ImageDetail(); if (context.testExpression("registryId", targetDepth)) { context.nextToken(); imageDetail.setRegistryId(context.getUnmarshaller(String.class).unmarshall(context)); imageDetail.setRepositoryName(context.getUnmarshaller(String.class).unmarshall(context)); imageDetail.setImageDigest(context.getUnmarshaller(String.class).unmarshall(context)); imageDetail.setImageTags(new ListUnmarshaller<String>(context.getUnmarshaller(String.class)).unmarshall(context)); imageDetail.setImageSizeInBytes(context.getUnmarshaller(Long.class).unmarshall(context)); imageDetail.setImagePushedAt(DateJsonUnmarshallerFactory.getInstance("unixTimestamp").unmarshall(context));
/** * <p> * The size, in bytes, of the image in the repository. * </p> * <note> * <p> * Beginning with Docker version 1.9, the Docker client compresses image layers before pushing them to a V2 Docker * registry. The output of the <code>docker images</code> command shows the uncompressed image size, so it may * return a larger image size than the image sizes returned by <a>DescribeImages</a>. * </p> * </note> * * @param imageSizeInBytes * The size, in bytes, of the image in the repository.</p> <note> * <p> * Beginning with Docker version 1.9, the Docker client compresses image layers before pushing them to a V2 * Docker registry. The output of the <code>docker images</code> command shows the uncompressed image size, * so it may return a larger image size than the image sizes returned by <a>DescribeImages</a>. * </p> * @return Returns a reference to this object so that method calls can be chained together. */ public ImageDetail withImageSizeInBytes(Long imageSizeInBytes) { setImageSizeInBytes(imageSizeInBytes); return this; }
return false; ImageDetail other = (ImageDetail) obj; if (other.getRegistryId() == null ^ this.getRegistryId() == null) return false; if (other.getRegistryId() != null && other.getRegistryId().equals(this.getRegistryId()) == false) return false; if (other.getRepositoryName() == null ^ this.getRepositoryName() == null) return false; if (other.getRepositoryName() != null && other.getRepositoryName().equals(this.getRepositoryName()) == false) return false; if (other.getImageDigest() == null ^ this.getImageDigest() == null) return false; if (other.getImageDigest() != null && other.getImageDigest().equals(this.getImageDigest()) == false) return false; if (other.getImageTags() == null ^ this.getImageTags() == null) return false; if (other.getImageTags() != null && other.getImageTags().equals(this.getImageTags()) == false) return false; if (other.getImageSizeInBytes() == null ^ this.getImageSizeInBytes() == null) return false; if (other.getImageSizeInBytes() != null && other.getImageSizeInBytes().equals(this.getImageSizeInBytes()) == false) return false; if (other.getImagePushedAt() == null ^ this.getImagePushedAt() == null) return false; if (other.getImagePushedAt() != null && other.getImagePushedAt().equals(this.getImagePushedAt()) == false) return false; return true;
/** * <p> * The <code>sha256</code> digest of the image manifest. * </p> * * @param imageDigest * The <code>sha256</code> digest of the image manifest. * @return Returns a reference to this object so that method calls can be chained together. */ public ImageDetail withImageDigest(String imageDigest) { setImageDigest(imageDigest); return this; }
/** * <p> * The date and time, expressed in standard JavaScript date format, at which the current image was pushed to the * repository. * </p> * * @param imagePushedAt * The date and time, expressed in standard JavaScript date format, at which the current image was pushed to * the repository. * @return Returns a reference to this object so that method calls can be chained together. */ public ImageDetail withImagePushedAt(java.util.Date imagePushedAt) { setImagePushedAt(imagePushedAt); return this; }
/** * Returns a string representation of this object. This is useful for testing and debugging. Sensitive data will be * redacted from this string using a placeholder value. * * @return A string representation of this object. * * @see java.lang.Object#toString() */ @Override public String toString() { StringBuilder sb = new StringBuilder(); sb.append("{"); if (getRegistryId() != null) sb.append("RegistryId: ").append(getRegistryId()).append(","); if (getRepositoryName() != null) sb.append("RepositoryName: ").append(getRepositoryName()).append(","); if (getImageDigest() != null) sb.append("ImageDigest: ").append(getImageDigest()).append(","); if (getImageTags() != null) sb.append("ImageTags: ").append(getImageTags()).append(","); if (getImageSizeInBytes() != null) sb.append("ImageSizeInBytes: ").append(getImageSizeInBytes()).append(","); if (getImagePushedAt() != null) sb.append("ImagePushedAt: ").append(getImagePushedAt()); sb.append("}"); return sb.toString(); }
/** * Marshall the given parameter object. */ public void marshall(ImageDetail imageDetail, ProtocolMarshaller protocolMarshaller) { if (imageDetail == null) { throw new SdkClientException("Invalid argument passed to marshall(...)"); } try { protocolMarshaller.marshall(imageDetail.getRegistryId(), REGISTRYID_BINDING); protocolMarshaller.marshall(imageDetail.getRepositoryName(), REPOSITORYNAME_BINDING); protocolMarshaller.marshall(imageDetail.getImageDigest(), IMAGEDIGEST_BINDING); protocolMarshaller.marshall(imageDetail.getImageTags(), IMAGETAGS_BINDING); protocolMarshaller.marshall(imageDetail.getImageSizeInBytes(), IMAGESIZEINBYTES_BINDING); protocolMarshaller.marshall(imageDetail.getImagePushedAt(), IMAGEPUSHEDAT_BINDING); } catch (Exception e) { throw new SdkClientException("Unable to marshall request to JSON: " + e.getMessage(), e); } }
@Override public int hashCode() { final int prime = 31; int hashCode = 1; hashCode = prime * hashCode + ((getRegistryId() == null) ? 0 : getRegistryId().hashCode()); hashCode = prime * hashCode + ((getRepositoryName() == null) ? 0 : getRepositoryName().hashCode()); hashCode = prime * hashCode + ((getImageDigest() == null) ? 0 : getImageDigest().hashCode()); hashCode = prime * hashCode + ((getImageTags() == null) ? 0 : getImageTags().hashCode()); hashCode = prime * hashCode + ((getImageSizeInBytes() == null) ? 0 : getImageSizeInBytes().hashCode()); hashCode = prime * hashCode + ((getImagePushedAt() == null) ? 0 : getImagePushedAt().hashCode()); return hashCode; }
return false; ImageDetail other = (ImageDetail) obj; if (other.getRegistryId() == null ^ this.getRegistryId() == null) return false; if (other.getRegistryId() != null && other.getRegistryId().equals(this.getRegistryId()) == false) return false; if (other.getRepositoryName() == null ^ this.getRepositoryName() == null) return false; if (other.getRepositoryName() != null && other.getRepositoryName().equals(this.getRepositoryName()) == false) return false; if (other.getImageDigest() == null ^ this.getImageDigest() == null) return false; if (other.getImageDigest() != null && other.getImageDigest().equals(this.getImageDigest()) == false) return false; if (other.getImageTags() == null ^ this.getImageTags() == null) return false; if (other.getImageTags() != null && other.getImageTags().equals(this.getImageTags()) == false) return false; if (other.getImageSizeInBytes() == null ^ this.getImageSizeInBytes() == null) return false; if (other.getImageSizeInBytes() != null && other.getImageSizeInBytes().equals(this.getImageSizeInBytes()) == false) return false; if (other.getImagePushedAt() == null ^ this.getImagePushedAt() == null) return false; if (other.getImagePushedAt() != null && other.getImagePushedAt().equals(this.getImagePushedAt()) == false) return false; return true;
/** * Returns a string representation of this object. This is useful for testing and debugging. Sensitive data will be * redacted from this string using a placeholder value. * * @return A string representation of this object. * * @see java.lang.Object#toString() */ @Override public String toString() { StringBuilder sb = new StringBuilder(); sb.append("{"); if (getRegistryId() != null) sb.append("RegistryId: ").append(getRegistryId()).append(","); if (getRepositoryName() != null) sb.append("RepositoryName: ").append(getRepositoryName()).append(","); if (getImageDigest() != null) sb.append("ImageDigest: ").append(getImageDigest()).append(","); if (getImageTags() != null) sb.append("ImageTags: ").append(getImageTags()).append(","); if (getImageSizeInBytes() != null) sb.append("ImageSizeInBytes: ").append(getImageSizeInBytes()).append(","); if (getImagePushedAt() != null) sb.append("ImagePushedAt: ").append(getImagePushedAt()); sb.append("}"); return sb.toString(); }
/** * Marshall the given parameter object. */ public void marshall(ImageDetail imageDetail, ProtocolMarshaller protocolMarshaller) { if (imageDetail == null) { throw new SdkClientException("Invalid argument passed to marshall(...)"); } try { protocolMarshaller.marshall(imageDetail.getRegistryId(), REGISTRYID_BINDING); protocolMarshaller.marshall(imageDetail.getRepositoryName(), REPOSITORYNAME_BINDING); protocolMarshaller.marshall(imageDetail.getImageDigest(), IMAGEDIGEST_BINDING); protocolMarshaller.marshall(imageDetail.getImageTags(), IMAGETAGS_BINDING); protocolMarshaller.marshall(imageDetail.getImageSizeInBytes(), IMAGESIZEINBYTES_BINDING); protocolMarshaller.marshall(imageDetail.getImagePushedAt(), IMAGEPUSHEDAT_BINDING); } catch (Exception e) { throw new SdkClientException("Unable to marshall request to JSON: " + e.getMessage(), e); } }