tinkerpop-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Marko A. Rodriguez (JIRA)" <j...@apache.org>
Subject [jira] [Commented] (TINKERPOP3-761) Some basic mathematical functions / steps
Date Wed, 05 Aug 2015 02:53:04 GMT

    [ https://issues.apache.org/jira/browse/TINKERPOP3-761?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=14654731#comment-14654731

Marko A. Rodriguez commented on TINKERPOP3-761:

I created TINKERPOP3-799. Few things to your comment.

1. You can't extend String. If you want the String value, just don't {{with()}} it. {{...addV('name','x').with('x',select('a').values('name'))}}
2. I don't see this as the same thing as TINKERPOP3-655 as {{with()}}-modulation would only
be applied to steps that can reasonably leverage it -- i.e. not every step.
3. {{select().with('a',...)}} is a nice idea. However, I would say we make it {{select().by('a',...)}}
if people want to be explicit. We can't mix the meaning of {{with()}} and {{by()}}. One if
for changing the arguments of a step on a per object basis ({{with()}}). The other is for
modulating the incoming values of a step ({{by()}}).

> Some basic mathematical functions / steps
> -----------------------------------------
>                 Key: TINKERPOP3-761
>                 URL: https://issues.apache.org/jira/browse/TINKERPOP3-761
>             Project: TinkerPop 3
>          Issue Type: Improvement
>          Components: process
>    Affects Versions: 3.0.0-incubating
>            Reporter: Daniel Kuppitz
>            Assignee: Marko A. Rodriguez
> Every once in a while I wish to have steps for some basic mathematical operations ({{add()}},
{{sub()}}, {{mul()}}, {{div()}}). Since {{sub(num)}} is the same as {{add(-num)}} and {{div(num)}}
is the same as {{mul(1/num)}}, we would only need two new step implementations.
> Oh, and then there's also {{mod()}}, thus 3 new step implementations.

This message was sent by Atlassian JIRA

View raw message