LibreOffice Module jvmaccess (master) 1
|
An encapsulating wrapper around a Java virtual machine and an appropriate UNO class loader. More...
#include <unovirtualmachine.hxx>
Classes | |
class | CreationException |
An exception indicating failure to create a UnoVirtualMachine. More... | |
Public Member Functions | |
UnoVirtualMachine (rtl::Reference< jvmaccess::VirtualMachine > virtualMachine, void *classLoader) | |
Create a wrapper around a Java virtual machine and an appropriate UNO class loader. More... | |
const rtl::Reference< jvmaccess::VirtualMachine > & | getVirtualMachine () const |
Get the Java virtual machine wrapper. More... | |
void * | getClassLoader () const |
Get the UNO class loader. More... | |
Public Member Functions inherited from salhelper::SimpleReferenceObject | |
SimpleReferenceObject () | |
void | acquire () |
void | release () |
Private Member Functions | |
UnoVirtualMachine (UnoVirtualMachine const &)=delete | |
UnoVirtualMachine & | operator= (UnoVirtualMachine const &)=delete |
virtual | ~UnoVirtualMachine () override |
Private Attributes | |
rtl::Reference< jvmaccess::VirtualMachine > | m_virtualMachine |
void * | m_classLoader |
Additional Inherited Members | |
Static Public Member Functions inherited from salhelper::SimpleReferenceObject | |
static void * | operator new (std::size_t nSize) |
static void * | operator new (std::size_t nSize, std::nothrow_t const &rNothrow) |
static void | operator delete (void *pPtr) |
static void | operator delete (void *pPtr, std::nothrow_t const &rNothrow) |
Protected Member Functions inherited from salhelper::SimpleReferenceObject | |
virtual | ~SimpleReferenceObject () COVERITY_NOEXCEPT_FALSE |
Protected Attributes inherited from salhelper::SimpleReferenceObject | |
oslInterlockedCount | m_nCount |
An encapsulating wrapper around a Java virtual machine and an appropriate UNO class loader.
Definition at line 35 of file unovirtualmachine.hxx.
jvmaccess::UnoVirtualMachine::UnoVirtualMachine | ( | rtl::Reference< jvmaccess::VirtualMachine > | virtualMachine, |
void * | classLoader | ||
) |
Create a wrapper around a Java virtual machine and an appropriate UNO class loader.
virtualMachine | A Java virtual machine wrapper. Must not be null. |
classLoader | A local or global JNI reference, relative to the given virtualMachine, to an appropriate UNO class loader instance. Must not be null. This parameter should be of type jobject, not void *, but the exact definition of jobject is different for different JDK versions, so that the mangled C++ name of the constructor would depend on the JDK version used at compile time. |
CreationException | Thrown in case creation fails (due to a JNI problem). |
Definition at line 43 of file unovirtualmachine.cxx.
References jvmaccess::VirtualMachine::AttachGuard, getEnvironment(), m_classLoader, and m_virtualMachine.
|
privatedelete |
|
overrideprivatevirtual |
Definition at line 64 of file unovirtualmachine.cxx.
References jvmaccess::VirtualMachine::AttachGuard, getEnvironment(), m_classLoader, m_virtualMachine, and SAL_INFO.
|
inline |
Get the UNO class loader.
Definition at line 85 of file unovirtualmachine.hxx.
const rtl::Reference< jvmaccess::VirtualMachine > & jvmaccess::UnoVirtualMachine::getVirtualMachine | ( | ) | const |
Get the Java virtual machine wrapper.
Definition at line 60 of file unovirtualmachine.cxx.
References m_virtualMachine.
|
privatedelete |
|
private |
Definition at line 94 of file unovirtualmachine.hxx.
Referenced by UnoVirtualMachine(), and ~UnoVirtualMachine().
|
private |
Definition at line 93 of file unovirtualmachine.hxx.
Referenced by getVirtualMachine(), UnoVirtualMachine(), and ~UnoVirtualMachine().