Code Monkey home page Code Monkey logo

Comments (4)

macisamuele avatar macisamuele commented on June 13, 2024

@Stranger6667 I'll try to update all the keywords in order to allow validation of a generic JsonType. I'll try to compare it with the benchmarks to identify possible regressions or additional issues

from jsonschema-rs.

Stranger6667 avatar Stranger6667 commented on June 13, 2024

Do you mean non-serde types?

from jsonschema-rs.

macisamuele avatar macisamuele commented on June 13, 2024

Ideally (at least this what I was experimenting with) the Validate trait should be modified into something like

trait Validate<J: JsonType> {
    fn validate(&self, schema: JsonSchema<J>, value: &J) -> ...;
    fn is_valid(&self, schema: JsonSchema<J>, value: &J) -> bool;
}

By doing so we might validate for any type J that implements JsonType trait.

If by doing it we don't introduce performance regressions then we might simplify the integration with foreign platforms (which might be Python or any other FFI) that adhere to JsonType trait.

Still this is a very preliminary idea, as I need to finalise the test branch to see the feasibility (especially comparing performances).

Once I have results (maybe over the weekend) I'll post something in here.

from jsonschema-rs.

Stranger6667 avatar Stranger6667 commented on June 13, 2024

Done in #54.

Sdist & wheels for manylinux2010 are here

from jsonschema-rs.

Related Issues (20)

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.