Package land.oras
Class ContainerRef
A referer of a container on a
Registry
.-
Field Summary
-
Method Summary
Modifier and TypeMethodDescriptionforRegistry
(String registry) Return a copy of reference for a registry other registryforRegistry
(Registry registry) Return a copy of reference for a registry other registryGet the algorithmGet the API registrygetApiRegistry
(@Nullable Registry target) Get the API registrygetBlobsPath
(@Nullable Registry registry) Return the blobs URLgetBlobsUploadDigestPath
(Registry registry) Return the blobs upload URL with the digest for single POST upload@Nullable String
Get the digestGet the full repository name including the namespace if anygetFullRepository
(@Nullable Registry registry) Get the full repository name including the namespace if anyReturn the manifests URLgetManifestsPath
(@Nullable Registry registry) Return the manifests URL@Nullable String
Get the namespace@Nullable String
getNamespace
(@Nullable Registry target) Get the effective namespace based on given registry tragetgetReferrersPath
(@Nullable ArtifactType artifactType) Return the referrers URL for this container referrergetReferrersPath
(@Nullable Registry registry, @Nullable ArtifactType artifactType) Return the referrers URL for this container referrerCreate a new container referenceReturn the catalog repositories URLgetRepositoriesPath
(@Nullable Registry target) Return the catalog repositories URLGet the repositoryReturn the tag URLgetTagsPath
(@Nullable Registry target) Return the tag URLstatic ContainerRef
Parse the container name into registry, repository and tag.withDigest
(String digest) Return the ref with the digest
-
Method Details
-
getRegistry
Create a new container reference- Returns:
- The new container reference
-
getFullRepository
Get the full repository name including the namespace if any- Parameters:
registry
- The registry- Returns:
- The full repository name
-
getFullRepository
Get the full repository name including the namespace if any- Returns:
- The full repository name
-
getApiRegistry
Get the API registry- Parameters:
target
- The target registry- Returns:
- The API registry
-
getApiRegistry
Get the API registry- Returns:
- The API registry
-
getNamespace
Get the namespace- Returns:
- The namespace
-
getNamespace
Get the effective namespace based on given registry traget- Parameters:
target
- The target registry- Returns:
- The effective namespace
-
getRepository
Get the repository- Specified by:
getRepository
in classRef<ContainerRef>
- Returns:
- The repository
-
getDigest
Get the digest- Returns:
- The digest
-
withDigest
Description copied from class:Ref
Return the ref with the digest- Specified by:
withDigest
in classRef<ContainerRef>
- Parameters:
digest
- The digest- Returns:
- The ref
-
getAlgorithm
Description copied from class:Ref
Get the algorithm- Specified by:
getAlgorithm
in classRef<ContainerRef>
- Returns:
- The algorithm
-
getRepositoriesPath
Return the catalog repositories URL- Parameters:
target
- The target registry- Returns:
- The tag URL
-
getRepositoriesPath
Return the catalog repositories URL- Returns:
- The tag URL
-
getTagsPath
Return the tag URL- Parameters:
target
- The target registry- Returns:
- The tag URL
-
getTagsPath
Return the tag URL- Returns:
- The tag URL
-
getReferrersPath
Return the referrers URL for this container referrer- Parameters:
artifactType
- The optional artifact typeregistry
- The optional registry- Returns:
- The referrers URL
-
getReferrersPath
Return the referrers URL for this container referrer- Parameters:
artifactType
- The optional artifact type- Returns:
- The referrers URL
-
getManifestsPath
Return the manifests URL- Parameters:
registry
- The registry- Returns:
- The manifests URL
-
getManifestsPath
Return the manifests URL- Returns:
- The manifests URL
-
getBlobsUploadDigestPath
Return the blobs upload URL with the digest for single POST upload- Parameters:
registry
- The registry- Returns:
- The blobs upload URL
-
getBlobsPath
Return the blobs URL- Parameters:
registry
- The registry- Returns:
- The blobs URL
-
parse
Parse the container name into registry, repository and tag.- Parameters:
name
- The full name of the container to parse with any components.- Returns:
- The container object with the registry, repository and tag.
-
forRegistry
Return a copy of reference for a registry other registry- Parameters:
registry
- The registry- Returns:
- The container reference
-
forRegistry
Return a copy of reference for a registry other registry- Parameters:
registry
- The registry- Returns:
- The container reference
-