Modulating By Column

32 views
Skip to first unread message

Yura A

unread,
Jul 25, 2018, 9:31:04 AM7/25/18
to Gremlin-users
Hello TinkerPop community,

Not sure if my question isn't dumb or where it is best to ask it, but I was wondering:
Is there any reason why ByModulating::modylateBy(Function) doesn't check for Column functions (and modulateBy of GroupStep), same as it is done in ByModulating::modulateBy(Function, Comparator) ?

Thanks and regards,
-Yura

Stephen Mallette

unread,
Jul 25, 2018, 10:46:22 AM7/25/18
to Gremlin-users
I guess it's because there is no 

by(Column) 

but there is a 

by(Column, Comparator)

--
You received this message because you are subscribed to the Google Groups "Gremlin-users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to gremlin-user...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/gremlin-users/142b218d-e63b-4629-ac4e-70bf2e4ae92c%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

Yura A

unread,
Jul 25, 2018, 10:56:31 AM7/25/18
to Gremlin-users
I'm blind, thanks :)

Though wouldn't adding following 'if' into modulateBy(function) work as well?

if (function instanceof Column)
    this.modulateBy(new ColumnTraversal((Column) function))



середа, 25 липня 2018 р. 17:46:22 UTC+3 користувач Stephen Mallette написав:

Stephen Mallette

unread,
Jul 25, 2018, 11:34:55 AM7/25/18
to Gremlin-users
That change seems to make sense to me. That's likely better than what it does now with:

this.modulateBy(__.map(new FunctionTraverser<>(function)).asAdmin());

Do you want to offer a pull request?

Yura A

unread,
Jul 25, 2018, 11:38:19 AM7/25/18
to Gremlin-users
sure, I would like to

середа, 25 липня 2018 р. 18:34:55 UTC+3 користувач Stephen Mallette написав:

Stephen Mallette

unread,
Aug 2, 2018, 7:14:39 AM8/2/18
to Gremlin-users
Reply all
Reply to author
Forward
0 new messages