Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/noamt/smarchive
The Smart Archive Input Stream
https://github.com/noamt/smarchive
Last synced: 16 days ago
JSON representation
The Smart Archive Input Stream
- Host: GitHub
- URL: https://github.com/noamt/smarchive
- Owner: noamt
- License: apache-2.0
- Created: 2015-10-26T16:28:38.000Z (about 9 years ago)
- Default Branch: master
- Last Pushed: 2015-10-30T05:09:35.000Z (about 9 years ago)
- Last Synced: 2023-03-11T16:26:38.853Z (almost 2 years ago)
- Language: Java
- Size: 211 KB
- Stars: 1
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.asciidoc
- License: LICENSE
Awesome Lists containing this project
README
= Smarchive - The Smart Archive =
== Backed by link:https://commons.apache.org/proper/commons-compress/[commons-compress], the Smart Archive detects and morphs into a specific archive stream ==
image:https://travis-ci.org/noamt/smarchive.svg?branch=master["Build Status", link="https://travis-ci.org/noamt/smarchive"]
image:https://api.bintray.com/packages/noamt/java-libraries/smarchive/images/download.svg[link="https://bintray.com/noamt/java-libraries/smarchive/_latestVersion"]
=== Abstract ===
At times you might have to handle an archive input stream but you will have no prior knowledge of the archiving method.
Based on the magic headers, the Smart Archive will auto-detect the archiving method and apply it accordingly.
Currently the support types are `tar`, `ar` and `zip`.
The Smart Archive will also apply a `GZip` filter if needed.=== Installation ===
If you haven't already done so, add JCenter to your repositories:
[source,groovy]
----
repositories {
jcenter()
}
----Then add the dependency to compile time:
[source,groovy]
----
dependencies {
compile 'org.10ne:smarchive:0.1'
}
----=== Usage ===
Usage is simple. To create a Smart Archive instance:
[source,java]
----
import org._10ne.smarchive.SmarchiveInputStream...
public void readArchiveEntries(InputStream inputStream) {
ArchiveInputStream archiveStream = SmarchiveInputStream.realize(inputStream);
...
}
----