Unless you are using Gremlin, Titan (and the Blueprints API) does not allow for a multi-setter for properties. Note that this is not true in Gremlin Groovy:
tialVertex.addEdge("temp",headVertex, [key1:"value1",key2:"value2"])
there are helper methods in Blueprints that you might find useful:
ElementHelper.setProperties(tialVertex.addEdge("temp",headVertex), "key1","value1","key2","value2")
Note that this approach offers no additional performance enhancements on insert. And of course, you could always just assign the Edge
to a variable and setProperty
from there:
Edge e = tialVertex.addEdge("temp",headVertex);
e.setProperty("key1","value1");
e.setProperty("key2","value2");