Package org.eclipse.aether.internal.impl
Class LocalPathPrefixComposerFactorySupport.LocalPathPrefixComposerSupport
- java.lang.Object
-
- org.eclipse.aether.internal.impl.LocalPathPrefixComposerFactorySupport.LocalPathPrefixComposerSupport
-
- All Implemented Interfaces:
LocalPathPrefixComposer
- Direct Known Subclasses:
DefaultLocalPathPrefixComposerFactory.DefaultLocalPathPrefixComposer
- Enclosing class:
- LocalPathPrefixComposerFactorySupport
protected abstract static class LocalPathPrefixComposerFactorySupport.LocalPathPrefixComposerSupport extends java.lang.Object implements LocalPathPrefixComposer
Support class for composers: it defines protected members for all the predefined configuration values and provides default implementation for methods. Implementors may change it's behaviour by overriding methods.
-
-
Field Summary
Fields Modifier and Type Field Description protected java.lang.String
localPrefix
protected java.lang.String
releasesPrefix
protected java.lang.String
remotePrefix
protected java.lang.String
snapshotsPrefix
protected boolean
split
protected boolean
splitLocal
protected boolean
splitRemote
protected boolean
splitRemoteRepository
protected boolean
splitRemoteRepositoryLast
-
Constructor Summary
Constructors Modifier Constructor Description protected
LocalPathPrefixComposerSupport(boolean split, java.lang.String localPrefix, boolean splitLocal, java.lang.String remotePrefix, boolean splitRemote, boolean splitRemoteRepository, boolean splitRemoteRepositoryLast, java.lang.String releasesPrefix, java.lang.String snapshotsPrefix)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description java.lang.String
getPathPrefixForLocalArtifact(Artifact artifact)
Gets the path prefix for a locally installed artifact.java.lang.String
getPathPrefixForLocalMetadata(Metadata metadata)
Gets the path prefix for locally installed metadata.java.lang.String
getPathPrefixForRemoteArtifact(Artifact artifact, RemoteRepository repository)
Gets the path prefix for an artifact cached from a remote repository.java.lang.String
getPathPrefixForRemoteMetadata(Metadata metadata, RemoteRepository repository)
Gets the path prefix for metadata cached from a remote repository.protected boolean
isSnapshot(Metadata metadata)
-
-
-
Field Detail
-
split
protected final boolean split
-
localPrefix
protected final java.lang.String localPrefix
-
splitLocal
protected final boolean splitLocal
-
remotePrefix
protected final java.lang.String remotePrefix
-
splitRemote
protected final boolean splitRemote
-
splitRemoteRepository
protected final boolean splitRemoteRepository
-
splitRemoteRepositoryLast
protected final boolean splitRemoteRepositoryLast
-
releasesPrefix
protected final java.lang.String releasesPrefix
-
snapshotsPrefix
protected final java.lang.String snapshotsPrefix
-
-
Constructor Detail
-
LocalPathPrefixComposerSupport
protected LocalPathPrefixComposerSupport(boolean split, java.lang.String localPrefix, boolean splitLocal, java.lang.String remotePrefix, boolean splitRemote, boolean splitRemoteRepository, boolean splitRemoteRepositoryLast, java.lang.String releasesPrefix, java.lang.String snapshotsPrefix)
-
-
Method Detail
-
getPathPrefixForLocalArtifact
public java.lang.String getPathPrefixForLocalArtifact(Artifact artifact)
Description copied from interface:LocalPathPrefixComposer
Gets the path prefix for a locally installed artifact.- Specified by:
getPathPrefixForLocalArtifact
in interfaceLocalPathPrefixComposer
- Parameters:
artifact
- The artifact for which to determine the prefix, must not benull
.- Returns:
- The prefix, may be
null
(note:null
s and empty strings are treated equally).
-
getPathPrefixForRemoteArtifact
public java.lang.String getPathPrefixForRemoteArtifact(Artifact artifact, RemoteRepository repository)
Description copied from interface:LocalPathPrefixComposer
Gets the path prefix for an artifact cached from a remote repository.- Specified by:
getPathPrefixForRemoteArtifact
in interfaceLocalPathPrefixComposer
- Parameters:
artifact
- The artifact for which to determine the prefix, must not benull
.repository
- The remote repository, nevernull
.- Returns:
- The prefix, may be
null
(note:null
s and empty strings are treated equally).
-
getPathPrefixForLocalMetadata
public java.lang.String getPathPrefixForLocalMetadata(Metadata metadata)
Description copied from interface:LocalPathPrefixComposer
Gets the path prefix for locally installed metadata.- Specified by:
getPathPrefixForLocalMetadata
in interfaceLocalPathPrefixComposer
- Parameters:
metadata
- The metadata for which to determine the prefix, must not benull
.- Returns:
- The prefix, may be
null
(note:null
s and empty strings are treated equally).
-
getPathPrefixForRemoteMetadata
public java.lang.String getPathPrefixForRemoteMetadata(Metadata metadata, RemoteRepository repository)
Description copied from interface:LocalPathPrefixComposer
Gets the path prefix for metadata cached from a remote repository.- Specified by:
getPathPrefixForRemoteMetadata
in interfaceLocalPathPrefixComposer
- Parameters:
metadata
- The metadata for which to determine the prefix, must not benull
.repository
- The remote repository, nevernull
.- Returns:
- The prefix, may be
null
(note:null
s and empty strings are treated equally).
-
isSnapshot
protected boolean isSnapshot(Metadata metadata)
-
-