TechnionYearlyProject / DailyPulseMe

A tool that tracks and analyzes your heart rate data during your calendar events, helping you live a healthier life.
https://dailypulse.azurewebsites.net
0 stars 1 forks source link

JSON-Jackson-Tree Model - 9 hours #85

Closed anadilhussein closed 6 years ago

anadilhussein commented 6 years ago

For Estimation time and Real Time Please take a look to issue #78

It will be more useful if we support other calendars in addition for Goo The object model API is similar to the Document Object Model (DOM) API for XML. It is a high-level API that provides immutable object models for JSON object and array structures. These JSON structures are represented as object models using the Java types JsonObject and JsonArray.

unfortunately ,JsonArray didn't help me, I faced another bug ! so I had to search new method, and I found this great tool "Jkson tree model"

Jackson Tree Model, In Jackson, you can use “Tree Model” to represent JSON, and perform the read and write operations via JsonNode, it is similar to an XML DOM tree.

to be able to work with Jakson, you need to add this dependency to the pom.xml file (I added extra / becasue the github make conversion to this text) </dependency/> </groupId/> org.json <//groupId/> </artifactId/>json</artifactId/> <//dependency/> capture

anadilhussein commented 6 years ago

my first Implementation using regex imp1

Second Implementation using Model Tree capture

First, the new Implementation solved the bug ,and second is more readable(JAJAJAJA =D) and short