OrientGraphFactory declareIntent not found

101 views
Skip to first unread message

Shishya

unread,
Mar 10, 2014, 4:50:07 AM3/10/14
to orient-...@googlegroups.com
Hi,

Is DelareIntent deprectaed in OrientGraphFactory?

I have the following code from pre 1.7rc1, but not working any more.

 
      OrientGraphFactory graph = new OrientGraphFactory("remote:0.0.0.0:2424/test","root","password");
       
System.out.println("Connected");
        graph
.declareIntent(new OIntentMassiveInsert());
Map<String, Object> mymap = new HashMap<String, Object>();
mymap.put("id" , "112");
       OrientVertex myv = graph.addVertex("class:myc", mymap);
myv.save();


Error is as follows.


 error: cannot find symbol
        graph
.declareIntent(new OIntentMassiveInsert());
             
^
  symbol
:   method declareIntent(OIntentMassiveInsert)
  location
: variable graph of type OrientGraphFactory
 error: cannot find symbol
        OrientVertex myv = graph.addVertex("class:myc", mymap);
  symbol:   method addVertex(String,Map<String,Object>)
  location: variable graph of type OrientGraphFactory



Odysseas

unread,
Mar 10, 2014, 9:12:51 AM3/10/14
to orient-...@googlegroups.com
You should be able to do something like:

graph.getTx().getRawGraph().declareIntent(new OIntentMassiveInsert());

prabhat

unread,
Mar 10, 2014, 10:41:56 AM3/10/14
to orient-...@googlegroups.com
Thanks,

Other question. How to get Functions.
As per the documenttaion, this doesnt work

OFunction citations = graph.getMetadata().getFunctionLibrary().getFunction("sum");

Thanks



--

---
You received this message because you are subscribed to a topic in the Google Groups "OrientDB" group.
To unsubscribe from this topic, visit https://groups.google.com/d/topic/orient-database/RJGCqIFNEdw/unsubscribe.
To unsubscribe from this group and all its topics, send an email to orient-databa...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

Luca Garulli

unread,
Mar 10, 2014, 11:02:44 AM3/10/14
to orient-database
Hi,
may you post the link to the non updated documentation?

Lvc@



--

---
You received this message because you are subscribed to the Google Groups "OrientDB" group.
To unsubscribe from this group and stop receiving emails from it, send an email to orient-databa...@googlegroups.com.

prabhat

unread,
Mar 10, 2014, 11:06:16 AM3/10/14
to orient-...@googlegroups.com

Luca Garulli

unread,
Mar 10, 2014, 11:41:38 AM3/10/14
to orient-database
Hi,
that example refers to the Document Database API you can get using:

ODatabaseDocumentTx db = graph.getRawGraph();

So you can do this:

OFunction citations = graph.getRawGraph().getMetadata().getFunctionLibrary().getFunction("sum");


Lvc@

Reply all
Reply to author
Forward
0 new messages