Salome HOME
projects
/
modules
/
yacs.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
Updated copyright comment
[modules/yacs.git]
/
src
/
runtime_swig
/
SALOMERuntime.i
diff --git
a/src/runtime_swig/SALOMERuntime.i
b/src/runtime_swig/SALOMERuntime.i
index 5c1d6df20d72fa4839c9227fd2d149167e7c08b4..40a200ad244b428f66c54499ffddeadbc3dd37e8 100644
(file)
--- a/
src/runtime_swig/SALOMERuntime.i
+++ b/
src/runtime_swig/SALOMERuntime.i
@@
-1,4
+1,4
@@
-// Copyright (C) 2006-20
16 CEA/DEN, EDF R&D
+// Copyright (C) 2006-20
24 CEA, EDF
//
// This library is free software; you can redistribute it and/or
// modify it under the terms of the GNU Lesser General Public
//
// This library is free software; you can redistribute it and/or
// modify it under the terms of the GNU Lesser General Public
@@
-66,6
+66,7
@@
#include "PyStdout.hxx"
#include "ExecutorSwig.hxx"
#include <sstream>
#include "PyStdout.hxx"
#include "ExecutorSwig.hxx"
#include <sstream>
+#include "Catalog.hxx"
%}
// ----------------------------------------------------------------------------
%}
// ----------------------------------------------------------------------------
@@
-78,10
+79,10
@@
if (!omnipy)
{
PyErr_SetString(PyExc_ImportError,(char*)"Cannot import _omnipy");
if (!omnipy)
{
PyErr_SetString(PyExc_ImportError,(char*)"Cannot import _omnipy");
- return;
+ return
NULL
;
}
PyObject* pyapi = PyObject_GetAttrString(omnipy, (char*)"API");
}
PyObject* pyapi = PyObject_GetAttrString(omnipy, (char*)"API");
- api = (omniORB
PYAPI*)PyCObject_AsVoidPtr(pyapi
);
+ api = (omniORB
pyAPI*)PyCapsule_GetPointer(pyapi,"_omnipy.API"
);
Py_DECREF(pyapi);
%}
Py_DECREF(pyapi);
%}
@@
-227,13
+228,22
@@
namespace YACS
// becomes a real derived class, this will have to be changed.
%rename(OptimizerAlgSync) YACS::ENGINE::PyOptimizerAlgBase;
%rename(OptimizerAlgASync) YACS::ENGINE::PyOptimizerAlgASync;
// becomes a real derived class, this will have to be changed.
%rename(OptimizerAlgSync) YACS::ENGINE::PyOptimizerAlgBase;
%rename(OptimizerAlgASync) YACS::ENGINE::PyOptimizerAlgASync;
+
%include "PyOptimizerAlg.hxx"
%include "PyOptimizerAlg.hxx"
+%newobject YACS::ENGINE::RuntimeSALOME::createAnyPyObject;
+
%extend YACS::ENGINE::RuntimeSALOME
{
PyObject *createContainer(const std::string& kind="")
{
YACS::ENGINE::Container *ret(self->createContainer(kind));
%extend YACS::ENGINE::RuntimeSALOME
{
PyObject *createContainer(const std::string& kind="")
{
YACS::ENGINE::Container *ret(self->createContainer(kind));
- return convertContainer2(ret);
+ return convertContainer2(ret,SWIG_POINTER_OWN | 0);
+ }
+
+ Any* createAnyPyObject(PyObject * pyobj)
+ {
+ return convertPyObjectNeutral(self->getBuiltinCatalog()->_typeMap["pyobj"],
+ pyobj);
}
}
}
}