Git Product home page Git Product logo

json-values's Issues

remove emptyObj() and emptyArray()

MutableMap, ImmutableMap don't have to implement emptyArray
MutableSeq,ImmutableSeq don't have to implement emptyObj

It makes really difficult to combine different map and seq implementations and doesn't make any sense...

creation of path with leading zeroes

Version of json-values you are using
all versions
Describe the bug
creation of path from a string doesn't return an error when an index is specified with leading zeroes
To Reproduce
JsPath.of("/a/001") doesn't return an error
Expected behavior
throw UserError with a suggestion removing leading zeroes

use of jackson api

to parse a string into a stream of token we are gonna use Jackson instead the customized parser from the Glassfish json implementation

Support for JSON-PATCH

JSON Patch is a format for describing changes to a JSON document. It can be used to avoid sending a whole document when only a part has changed.

improve javadoc

All public methods and classes have been well documented. Do the same for none public classes and methods.

rename non public classes

Some of the non-public classes have the prefix "My" to distinguish from the public classes. It's a bit overkilling

release 4.0.0

After thinking for a while, I'm going to stick to Scala immutable HashMap and Vector as the underlying data structures of the immutable Json. The API won't provide a way of using others. Ther parsing of a String into a Stream of tokens will be made using Jackson because it's a well-tested library and I don't want to maintain any code related to this task. Some performance optimization has been carried out, and the improvements are significant compared to the previous release; also, the size of the jar is half the size it was.
.

remove the generic types in MyMap and MySeq that are not used

Do some refactor. In previous versions to 3.1.0, MyMap implementations needed to create empty arrays and MySeq implementations needed to create empty objects, that's why there were two generic types.
After version 3.1.0, that tight coupling between seqs and maps has been removed, but those types remain...

//remove V type
interface MyMap<M extends MyMap<M, V>, V extends MySeq<V, M>>

// MySeq is not used in after last release (3.1.0):
interface MyMap<M extends MyMap<M>>

and

// remove M type
interface MySeq<V extends MySeq<V, M>, M extends MyMap<M, V>> extends Iterable<JsElem>

//MyMap is not used in after last release (3.1.0)
interface MySeq<V extends MySeq<V>> extends Iterable<JsElem>

Remove static factory methods from JsObj and JsArray

Static factory methods have the inconvenient of making difficult to use different data structures that the specified in them. The JsObj and JsArray are tightly coupled to the underlying data structures. It would be interesting to be able to define factories with custom
data structures. For example, a JsArray could use a list implementation from Eclipse Collections or a vector from Clojure or even a Set from Java. It makes the library more attractive and more object-oriented.

cut down size of jar

It's a uber jar and a lot of classes from scala are packaged, and they are not needed

release 3.0.0: configuration

change versions in pom
add release name
generate changelog from the commit history
pull request into master and tag master to trigger Travis release process

wrong error message

Version of json-values you are using
2.0.1
Describe the bug

 JsObj.parse("").orElseThrow() 

returns the message

 jsonvalues.MalformedJson thrown: Invalid token=EOF at (line no=1, column no=0, offset=-1). Expected tokens are: [CURLYOPEN, SQUAREOPEN, STRING, NUMBER, TRUE, FALSE, NULL]

Expected behavior
Expected tokens are: [CURLYOPEN, SQUAREOPEN]

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.