GithubHelp home page GithubHelp logo

Comments (5)

barakmich avatar barakmich commented on July 30, 2024

These sound pretty straightforward -- it'd be interesting to try to build the tree, however.

A "Not" iterator seems reasonable here to make Except happen. It's a little like optional in that it shouldn't be nexted (or, if it is, it's expensive) and is defined as an (All minus (whatever subiterator))

The more we can delay evaluation, the better we could (potentially) optimize things. Worth keeping in mind at least -- it doesn't have to do that today.

from cayley.

pbnjay avatar pbnjay commented on July 30, 2024

Yeah my initial thinking is that "aggregate" basically populates a FixedIterator, and then that can be used for the checks. I'd also want to create a special-case FixedIterator which uses a map[Value] to make sure Check()s are fast vs the current slice-backed implementation.

Although that means Values might need a consistent hash representation...

from cayley.

barakmich avatar barakmich commented on July 30, 2024

Or at least that they have a reasonable Hash function, ie, changing graph.TSVal from an interface{} to, well, an actual interface.

from cayley.

kortschak avatar kortschak commented on July 30, 2024

An alternative to enforcing a Hash implementation is to conditionally type assert and use the Hash method if it exists or fall back to hashing the value otherwise. On the downside, this would be somewhat slower and is a little magical (would need to be documented).

Or at least that they have a reasonable Hash function, ie, changing graph.TSVal from an interface{} to, well, an actual interface.

from cayley.

robertmeta avatar robertmeta commented on July 30, 2024

Moved this over to feature requests as it seems to have been sitting here without much implementation for a long time, maybe over there it will generate some new excitement: https://discourse.cayley.io/t/add-gremlin-except-and-retain-filtering-methods/239

from cayley.

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.