Class SimpleIndexer


  • public class SimpleIndexer
    extends java.lang.Object
    Simple program to generate an index from a set of bundles.
    • Constructor Detail

      • SimpleIndexer

        public SimpleIndexer()
    • Method Detail

      • files

        public SimpleIndexer files​(java.util.Collection<java.io.File> files)
        Adds files to be indexed.
        Parameters:
        files - the files to include in the index
      • base

        public SimpleIndexer base​(java.net.URI base)
        Parameters:
        base - the base URI from which the index urls are relative
      • compress

        public SimpleIndexer compress​(boolean compress)
        Parameters:
        compress - compress with GZIP when true
      • name

        public SimpleIndexer name​(java.lang.String name)
        Parameters:
        name - an optional name for the index
      • increment

        public SimpleIndexer increment​(long increment)
        Parameters:
        increment - the timestamp of the index
      • index

        public void index​(java.io.OutputStream outputStream)
                   throws java.io.IOException
        Generate the index to the specified output stream.
        Parameters:
        outputStream - the output stream to write the index file
        Throws:
        java.io.IOException - if a file cannot be indexed
      • index

        public void index​(java.io.File file)
                   throws java.io.IOException
        Generate the index to the specified file.
        Parameters:
        file - the file to write the index file
        Throws:
        java.io.IOException - if a file cannot be indexed
      • getResources

        public java.util.List<org.osgi.resource.Resource> getResources()
        Return the resources so far.
        Returns:
        the set of resources handled so far.
      • reporter

        public SimpleIndexer reporter​(aQute.service.reporter.Reporter reporter)