Class MavenChainedWorkspaceReader

  • All Implemented Interfaces:
    org.apache.maven.repository.internal.MavenWorkspaceReader, org.eclipse.aether.repository.WorkspaceReader

    public final class MavenChainedWorkspaceReader
    extends java.lang.Object
    implements org.apache.maven.repository.internal.MavenWorkspaceReader
    A maven workspace reader that delegates to a chain of other readers, effectively aggregating their contents.
    • Method Summary

      All Methods Static Methods Instance Methods Concrete Methods 
      Modifier and Type Method Description
      java.io.File findArtifact​(org.eclipse.aether.artifact.Artifact artifact)  
      org.apache.maven.model.Model findModel​(org.eclipse.aether.artifact.Artifact artifact)  
      java.util.List<java.lang.String> findVersions​(org.eclipse.aether.artifact.Artifact artifact)  
      org.eclipse.aether.repository.WorkspaceRepository getRepository()  
      static org.eclipse.aether.repository.WorkspaceReader of​(java.util.Collection<org.eclipse.aether.repository.WorkspaceReader> workspaceReaderCollection)
      chains a collection of WorkspaceReaders
      • Methods inherited from class java.lang.Object

        clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
    • Method Detail

      • findModel

        public org.apache.maven.model.Model findModel​(org.eclipse.aether.artifact.Artifact artifact)
        Specified by:
        findModel in interface org.apache.maven.repository.internal.MavenWorkspaceReader
      • getRepository

        public org.eclipse.aether.repository.WorkspaceRepository getRepository()
        Specified by:
        getRepository in interface org.eclipse.aether.repository.WorkspaceReader
      • findArtifact

        public java.io.File findArtifact​(org.eclipse.aether.artifact.Artifact artifact)
        Specified by:
        findArtifact in interface org.eclipse.aether.repository.WorkspaceReader
      • findVersions

        public java.util.List<java.lang.String> findVersions​(org.eclipse.aether.artifact.Artifact artifact)
        Specified by:
        findVersions in interface org.eclipse.aether.repository.WorkspaceReader
      • of

        public static org.eclipse.aether.repository.WorkspaceReader of​(java.util.Collection<org.eclipse.aether.repository.WorkspaceReader> workspaceReaderCollection)
        chains a collection of WorkspaceReaders
        Parameters:
        workspaceReaderCollection - the collection of readers, might be empty but never null
        Returns:
        if the collection contains only one item returns the single item, otherwise creates a new MavenChainedWorkspaceReader chaining all readers in the order of the given collection.