Browse Source

minimal version for stormpy expressions, some questions should be resolved first (regarding to manager)

Former-commit-id: 18c0d094c2
tempestpy_adaptions
sjunges 9 years ago
parent
commit
7cf2446501
  1. 3
      setup.py
  2. 3
      src/python/CMakeLists.txt
  3. 19
      src/python/storm-expression.cpp
  4. 1
      stormpy/expressions/__init__.py

3
setup.py

@ -74,10 +74,11 @@ setup(cmdclass={'install': MyInstall, 'develop': MyDevelop, 'egg_info': MyEggInf
version="0.2", version="0.2",
description="Stormpy - Python Bindings for Storm", description="Stormpy - Python Bindings for Storm",
package_dir={'':d}, package_dir={'':d},
packages=['stormpy', 'stormpy.core', 'stormpy.info', 'stormpy.logic'],
packages=['stormpy', 'stormpy.core', 'stormpy.info', 'stormpy.logic', 'stormpy.expressions'],
package_data={'stormpy.core': ['_core.so'], package_data={'stormpy.core': ['_core.so'],
'stormpy.logic': ['_logic.so'], 'stormpy.logic': ['_logic.so'],
'stormpy.info' : ['_info.so'] , 'stormpy.info' : ['_info.so'] ,
'stormpy.expressions' : ['_expressions.so'],
'stormpy': ['*.so', '*.dylib', '*.a']}, 'stormpy': ['*.so', '*.dylib', '*.a']},
include_package_data=True) include_package_data=True)

3
src/python/CMakeLists.txt

@ -21,5 +21,6 @@ if(STORM_PYTHON)
add_python_module(stormpy-info info ${CMAKE_CURRENT_SOURCE_DIR}/storm-info.cpp) add_python_module(stormpy-info info ${CMAKE_CURRENT_SOURCE_DIR}/storm-info.cpp)
add_python_module(stormpy-core core ${CMAKE_CURRENT_SOURCE_DIR}/storm-core.cpp) add_python_module(stormpy-core core ${CMAKE_CURRENT_SOURCE_DIR}/storm-core.cpp)
add_python_module(stormpy-logic logic ${CMAKE_CURRENT_SOURCE_DIR}/storm-logic.cpp) add_python_module(stormpy-logic logic ${CMAKE_CURRENT_SOURCE_DIR}/storm-logic.cpp)
add_custom_target(stormpy DEPENDS stormpy-info stormpy-core stormpy-logic)
add_python_module(stormpy-expression expressions ${CMAKE_CURRENT_SOURCE_DIR}/storm-expression.cpp)
add_custom_target(stormpy DEPENDS stormpy-info stormpy-core stormpy-logic stormpy-expression)
endif() endif()

19
src/python/storm-expression.cpp

@ -0,0 +1,19 @@
#include <boost/python.hpp>
#include <boost/python/suite/indexing/vector_indexing_suite.hpp>
#include "helpers.h"
#include "boostPyExtension.h"
#include "../storage/expressions/ExpressionManager.h"
BOOST_PYTHON_MODULE(_expressions)
{
using namespace boost::python;
defineClass<storm::expressions::ExpressionManager, void, boost::noncopyable>("ExpressionManager",
"Manages variables for expressions");
defineClass<storm::expressions::Expression, void, boost::noncopyable>("Expression",
"");
}

1
stormpy/expressions/__init__.py

@ -0,0 +1 @@
from stormpy.expressions._expressions import *
Loading…
Cancel
Save