Integrate Python And C++

Interfacing Python with C/C++ is not an easy task. Here I copy/paste a previous answer on a previous question for the different methods to write a python extension. Featuring Boost.Python, SWIG, Pybindgen… You can write an extension yourself in C or C++ with the Python C-API. In a word: don’t do that except for learning … Read more

Java Python Integration

Why not use Jython? The only downside I can immediately think of is if your library uses CPython native extensions. EDIT: If you can use Jython now but think you may have problems with a later version of the library, I suggest you try to isolate the library from your app (e.g. some sort of … Read more

Spring JSF integration: how to inject a Spring component/service in JSF managed bean?

@ManagedBean vs @Controller First of all, you should choose one framework to manage your beans. You should choose either JSF or Spring (or CDI) to manage your beans. Whilst the following works, it is fundamentally wrong: @ManagedBean // JSF-managed. @Controller // Spring-managed. public class BadBean {} You end up with two completely separate instances of … Read more