File tree Expand file tree Collapse file tree 6 files changed +20
-14
lines changed
Expand file tree Collapse file tree 6 files changed +20
-14
lines changed Original file line number Diff line number Diff line change @@ -19,7 +19,7 @@ Add Sift to your application’s build.gradle file:
1919```
2020dependencies {
2121 ...
22- compile 'com.siftscience:sift-android:0.9.5 '
22+ compile 'com.siftscience:sift-android:0.9.6 '
2323 ...
2424}
2525```
Original file line number Diff line number Diff line change 1717# http://www.gradle.org/docs/current/userguide/multi_project_builds.html#sec:decoupled_projects
1818# org.gradle.parallel=true
1919
20- VERSION_NAME =0.9.5
20+ VERSION_NAME =0.9.6
2121VERSION_CODE =5
2222
2323GROUP =com.siftscience
Original file line number Diff line number Diff line change @@ -22,7 +22,7 @@ android {
2222 minSdkVersion 16 // Jelly Bean 4.1.x (basically Java 6)
2323 targetSdkVersion 25
2424 versionCode 5
25- versionName ' 0.9.5 '
25+ versionName ' 0.9.6 '
2626
2727 consumerProguardFiles ' proguard-rules.pro'
2828 }
Original file line number Diff line number Diff line change 2828
2929/** The main class of the Sift client library. */
3030public class Sift {
31- public static final String SDK_VERSION = "0.9.5 " ;
31+ public static final String SDK_VERSION = "0.9.6 " ;
3232 private static final String TAG = Sift .class .getName ();
3333
3434 private static Sift instance ;
Original file line number Diff line number Diff line change 1010import com .fasterxml .jackson .annotation .JsonAutoDetect ;
1111import com .fasterxml .jackson .core .JsonProcessingException ;
1212import com .sift .api .representations .MobileEventJson ;
13+ import com .sift .api .representations .ListRequestJson ;
1314
1415import java .io .ByteArrayOutputStream ;
1516import java .io .IOException ;
@@ -251,15 +252,6 @@ public void run() {
251252 }
252253 };
253254
254- /** The list request class as defined in Sift API doc. */
255- @ JsonAutoDetect (fieldVisibility = JsonAutoDetect .Visibility .ANY )
256- private static class ListRequest {
257- final List <MobileEventJson > data ;
258- ListRequest (List <MobileEventJson > data ) {
259- this .data = data ;
260- }
261- }
262-
263255 private static final MediaType JSON = MediaType .parse ("application/json" );
264256
265257 // StandardCharsets.US_ASCII is defined in API level 19 and we are
@@ -292,7 +284,9 @@ private Request makeRequest() throws IOException {
292284 String encodedBeaconKey = Base64 .encodeToString (config .beaconKey .getBytes (US_ASCII ),
293285 Base64 .NO_WRAP );
294286
295- ListRequest request = new ListRequest (events );
287+ ListRequestJson <MobileEventJson > request = ListRequestJson .<MobileEventJson >newBuilder ()
288+ .withData (events )
289+ .build ();
296290
297291 byte [] data = Sift .JSON .writeValueAsBytes (request );
298292 ByteArrayOutputStream os = new ByteArrayOutputStream ();
Original file line number Diff line number Diff line change 1+ ---
2+ title : ListRequest
3+ description : user submits a collection
4+ type : object
5+ javaType : com.sift.api.representations.ListRequestJson<T>
6+ properties :
7+ data :
8+ type : array
9+ items :
10+ type : object
11+ javaType : T
12+ additionalProperties : false
You can’t perform that action at this time.
0 commit comments