Class ArchiveReader
- java.lang.Object
-
- org.apache.sling.feature.io.archive.ArchiveReader
-
public class ArchiveReader extends Object
The feature archive reader can be used to read an archive based on a feature model. The archive contains the model and all artifacts.
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description static interface
ArchiveReader.ArtifactConsumer
-
Constructor Summary
Constructors Constructor Description ArchiveReader()
-
Method Summary
All Methods Static Methods Concrete Methods Modifier and Type Method Description static Set<Feature>
read(InputStream in, ArchiveReader.ArtifactConsumer consumer)
Read a feature model archive.
-
-
-
Method Detail
-
read
public static Set<Feature> read(InputStream in, ArchiveReader.ArtifactConsumer consumer) throws IOException
Read a feature model archive. The input stream is not closed. It is up to the caller to close the input stream.- Parameters:
in
- The input stream to read from.consumer
- The plugin consuming the binaries, including the features. If no consumer is provided, only the features will be returned.- Returns:
- The feature models mentioned in the manifest of the archive
- Throws:
IOException
- If anything goes wrong
-
-