Skip to content

Commit

Permalink
Update RM.
Browse files Browse the repository at this point in the history
  • Loading branch information
郑晓勇 committed Oct 10, 2017
1 parent f123a5e commit ce77876
Showing 1 changed file with 8 additions and 7 deletions.
15 changes: 8 additions & 7 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,7 @@ or
### **Installation**

```
compile 'com.zxy.android:tiny:0.0.7'
compile 'com.zxy.android:tiny:0.1.0'
```

### **Choose an abi**
Expand Down Expand Up @@ -59,7 +59,7 @@ android {
//options.height = xxx;//some compression configuration.
Tiny.getInstance().source("").asBitmap().withOptions(options).compress(new BitmapCallback() {
@Override
public void callback(boolean isSuccess, Bitmap bitmap) {
public void callback(boolean isSuccess, Bitmap bitmap, Throwable t) {
//return the compressed bitmap object
}
});
Expand All @@ -71,7 +71,7 @@ android {
Tiny.FileCompressOptions options = new Tiny.FileCompressOptions();
Tiny.getInstance().source("").asFile().withOptions(options).compress(new FileCallback() {
@Override
public void callback(boolean isSuccess, String outfile) {
public void callback(boolean isSuccess, String outfile, Throwable t) {
//return the compressed file path
}
});
Expand All @@ -82,7 +82,7 @@ android {
Tiny.FileCompressOptions options = new Tiny.FileCompressOptions();
Tiny.getInstance().source("").asFile().withOptions(options).compress(new FileWithBitmapCallback() {
@Override
public void callback(boolean isSuccess, Bitmap bitmap, String outfile) {
public void callback(boolean isSuccess, Bitmap bitmap, String outfile, Throwable t) {
//return the compressed file path and bitmap object
}
});
Expand All @@ -94,7 +94,7 @@ android {
Tiny.BitmapCompressOptions options = new Tiny.BitmapCompressOptions();
Tiny.getInstance().source("").batchAsBitmap().withOptions(options).batchCompress(new BitmapBatchCallback() {
@Override
public void callback(boolean isSuccess, Bitmap[] bitmaps) {
public void callback(boolean isSuccess, Bitmap[] bitmaps, Throwable t) {
//return the batch compressed bitmap object
}
});
Expand All @@ -105,7 +105,7 @@ android {
Tiny.FileCompressOptions options = new Tiny.FileCompressOptions();
Tiny.getInstance().source("").batchAsFile().withOptions(options).batchCompress(new FileBatchCallback() {
@Override
public void callback(boolean isSuccess, String[] outfile) {
public void callback(boolean isSuccess, String[] outfile, Throwable t) {
//return the batch compressed file path
}
});
Expand All @@ -116,7 +116,7 @@ android {
Tiny.FileCompressOptions options = new Tiny.FileCompressOptions();
Tiny.getInstance().source("").batchAsFile().withOptions(options).batchCompress(new FileWithBitmapBatchCallback() {
@Override
public void callback(boolean isSuccess, Bitmap[] bitmaps, String[] outfile) {
public void callback(boolean isSuccess, Bitmap[] bitmaps, String[] outfile, Throwable t) {
//return the batch compressed file path and bitmap object
}
});
Expand All @@ -131,6 +131,7 @@ android {
* **v0.0.5**:Fix google store reject.
* **v0.0.6**:Initialization is not must.Add clear compression directory method,see`{@link Tiny#clearCompressDirectory}`
* **v0.0.7**:fix issue#29
* **v0.1.0**:Add exception thrown interface, add the `Throwable` parameter to the callback method `{@link xxxxCallback#callback}`

## **License**

Expand Down

0 comments on commit ce77876

Please sign in to comment.