MarcosPividori / atomspace

The OpenCog hypergraph database and logic (reasoning) engine
Other
0 stars 0 forks source link

Support Multiples Atomspaces #9

Closed MarcosPividori closed 9 years ago

MarcosPividori commented 9 years ago

Now:

  main = runOnNewAtomSpace $ do 
                               asAddNode  (Node ....)
                               asAddLink  (Link ....)

With multiples atomspaces:

  main = do
           a1  <-  createAtomSpace
           a2  <-  createAtomSpace
           addNode a1 (Node ...)
           addNode a2 (Node ...)
           ....

I plan to offer both options. As it is more common to work with only one atomspace, the first approach is far more confortable because you avoid passing the atomspace instance as an argument each time for each action.

MarcosPividori commented 9 years ago

done after: https://github.com/opencog/atomspace/pull/222