gremlin> Vertex.metaClass.setProps = { Map map ->for(entry in map) {delegate.property(entry.key, entry.value);}}
==>groovysh_evaluate$_run_closure1@650aa077
gremlin> g.V(81924240).setProps([age:31])
No signature of method: org.apache.tinkerpop.gremlin.process.traversal.dsl.graph.DefaultGraphTraversal.setProps() is applicable for argument types: (java.util.LinkedHashMap) values: [[age:31]]
Possible solutions: setGraph(org.apache.tinkerpop.gremlin.structure.Graph), getGraph(), getSteps(), setParent(org.apache.tinkerpop.gremlin.process.traversal.step.TraversalParent)
Display stack trace? [yN]
Enter code here...
--
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/bbeb8204-fb7d-4e1e-853d-e40d135456cf%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.
delegate.setProperty(entry.key, entry.value)
delegate.property(entry.key, entry.value)
g2.V(122884200).setProps([age:31])
No signature of method: org.apache.tinkerpop.gremlin.process.traversal.dsl.graph.DefaultGraphTraversal.setProps() is applicable for argument types: (java.util.LinkedHashMap) values: [[age:31]]Possible solutions: setGraph(org.apache.tinkerpop.gremlin.structure.Graph), getGraph(), getSteps(), setParent(org.apache.tinkerpop.gremlin.process.traversal.step.TraversalParent)
Display stack trace? [yN] ygroovy.lang.MissingMethodException: No signature of method: org.apache.tinkerpop.gremlin.process.traversal.dsl.graph.DefaultGraphTraversal.setProps() is applicable for argument types: (java.util.LinkedHashMap) values: [[age:31]]
Possible solutions: setGraph(org.apache.tinkerpop.gremlin.structure.Graph), getGraph(), getSteps(), setParent(org.apache.tinkerpop.gremlin.process.traversal.step.TraversalParent)
at org.codehaus.groovy.runtime.ScriptBytecodeAdapter.unwrap(ScriptBytecodeAdapter.java:56) at org.codehaus.groovy.runtime.callsite.PojoMetaClassSite.call(PojoMetaClassSite.java:46) at org.codehaus.groovy.runtime.callsite.CallSiteArray.defaultCall(CallSiteArray.java:45) at org.codehaus.groovy.runtime.callsite.AbstractCallSite.call(AbstractCallSite.java:110) at org.codehaus.groovy.runtime.callsite.AbstractCallSite.call(AbstractCallSite.java:122) at groovysh_evaluate.run(groovysh_evaluate:3) at org.codehaus.groovy.vmplugin.v7.IndyInterface.selectMethod(IndyInterface.java:215) at org.codehaus.groovy.tools.shell.Interpreter.evaluate(Interpreter.groovy:69) at org.codehaus.groovy.tools.shell.Groovysh.execute(Groovysh.groovy:185) at org.codehaus.groovy.tools.shell.Shell.leftShift(Shell.groovy:119) at org.codehaus.groovy.tools.shell.ShellRunner.work(ShellRunner.groovy:94) at org.codehaus.groovy.tools.shell.InteractiveShellRunner.super$2$work(InteractiveShellRunner.groovy) at sun.reflect.GeneratedMethodAccessor32.invoke(Unknown Source) at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) at java.lang.reflect.Method.invoke(Method.java:497) at org.codehaus.groovy.reflection.CachedMethod.invoke(CachedMethod.java:90) at groovy.lang.MetaMethod.doMethodInvoke(MetaMethod.java:324) at groovy.lang.MetaClassImpl.invokeMethod(MetaClassImpl.java:1207) at org.codehaus.groovy.runtime.ScriptBytecodeAdapter.invokeMethodOnSuperN(ScriptBytecodeAdapter.java:130) at org.codehaus.groovy.runtime.ScriptBytecodeAdapter.invokeMethodOnSuper0(ScriptBytecodeAdapter.java:150) at org.codehaus.groovy.tools.shell.InteractiveShellRunner.work(InteractiveShellRunner.groovy:123) at org.codehaus.groovy.tools.shell.ShellRunner.run(ShellRunner.groovy:58) at org.codehaus.groovy.tools.shell.InteractiveShellRunner.super$2$run(InteractiveShellRunner.groovy) at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62) at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) at java.lang.reflect.Method.invoke(Method.java:497) at org.codehaus.groovy.reflection.CachedMethod.invoke(CachedMethod.java:90) at groovy.lang.MetaMethod.doMethodInvoke(MetaMethod.java:324) at groovy.lang.MetaClassImpl.invokeMethod(MetaClassImpl.java:1207) at org.codehaus.groovy.runtime.ScriptBytecodeAdapter.invokeMethodOnSuperN(ScriptBytecodeAdapter.java:130) at org.codehaus.groovy.runtime.ScriptBytecodeAdapter.invokeMethodOnSuper0(ScriptBytecodeAdapter.java:150) at org.codehaus.groovy.tools.shell.InteractiveShellRunner.run(InteractiveShellRunner.groovy:82) at org.codehaus.groovy.vmplugin.v7.IndyInterface.selectMethod(IndyInterface.java:215) at org.apache.tinkerpop.gremlin.console.Console.<init>(Console.groovy:144) at org.codehaus.groovy.vmplugin.v7.IndyInterface.selectMethod(IndyInterface.java:215) at org.apache.tinkerpop.gremlin.console.Console.main(Console.groovy:303)
gremlin> graph = TinkerGraph.open()
==>tinkergraph[vertices:0 edges:0]
gremlin> g = graph.traversal()
==>graphtraversalsource[tinkergraph[vertices:0 edges:0], standard]
gremlin> v = g.addV().next()
==>v[0]
gremlin> m = ['name':'javid','num':123456]
==>name=javid
==>num=123456
gremlin> m.each{ key, value -> v.property(key, value) }
==>name=javid
==>num=123456
gremlin> v.properties()
==>vp[num->123456]
==>vp[name->javid]
To view this discussion on the web visit https://groups.google.com/d/msgid/gremlin-users/de88e8cd-8d58-47b2-9246-a91638b540ad%40googlegroups.com.