Class ObrIndex

  • All Implemented Interfaces:
    org.apache.maven.plugin.ContextEnabled, org.apache.maven.plugin.Mojo

    @Mojo(name="index",
          requiresProject=false)
    public final class ObrIndex
    extends org.apache.maven.plugin.AbstractMojo
    Index the content of a maven repository using OBR
    • Field Summary

      Fields 
      Modifier and Type Field Description
      private java.io.FileFilter filter  
      private org.apache.maven.artifact.repository.ArtifactRepository localRepository
      Local Repository.
      private java.lang.String mavenRepository
      The repository to index
      private java.lang.String obrRepository
      OBR Repository.
      private java.lang.String urlTemplate
      Template for urls
      • Fields inherited from interface org.apache.maven.plugin.Mojo

        ROLE
    • Constructor Summary

      Constructors 
      Constructor Description
      ObrIndex()  
    • Method Summary

      All Methods Instance Methods Concrete Methods 
      Modifier and Type Method Description
      protected void doTemplate​(java.net.URI root, java.io.File path, org.apache.felix.bundlerepository.impl.ResourceImpl resource)  
      void execute()  
      private void findAllJars​(java.io.File mainRoot, java.util.List<java.io.File> files)  
      private java.lang.String trim​(java.lang.String prefix, java.lang.String path)  
      • Methods inherited from class org.apache.maven.plugin.AbstractMojo

        getLog, getPluginContext, setLog, setPluginContext
      • Methods inherited from class java.lang.Object

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

      • obrRepository

        @Parameter(property="obrRepository")
        private java.lang.String obrRepository
        OBR Repository.
      • urlTemplate

        @Parameter(property="urlTemplate")
        private java.lang.String urlTemplate
        Template for urls
      • mavenRepository

        @Parameter(property="mavenRepository")
        private java.lang.String mavenRepository
        The repository to index
      • localRepository

        @Parameter(defaultValue="${localRepository}",
                   readonly=true,
                   required=true)
        private org.apache.maven.artifact.repository.ArtifactRepository localRepository
        Local Repository.
      • filter

        private final java.io.FileFilter filter
    • Constructor Detail

      • ObrIndex

        public ObrIndex()
    • Method Detail

      • execute

        public void execute()
                     throws org.apache.maven.plugin.MojoExecutionException
        Throws:
        org.apache.maven.plugin.MojoExecutionException
      • doTemplate

        protected void doTemplate​(java.net.URI root,
                                  java.io.File path,
                                  org.apache.felix.bundlerepository.impl.ResourceImpl resource)
                           throws java.io.IOException,
                                  java.net.URISyntaxException
        Throws:
        java.io.IOException
        java.net.URISyntaxException
      • trim

        private java.lang.String trim​(java.lang.String prefix,
                                      java.lang.String path)
      • findAllJars

        private void findAllJars​(java.io.File mainRoot,
                                 java.util.List<java.io.File> files)