diff options
Diffstat (limited to 'scripting/source/basprov/basscript.hxx')
-rw-r--r-- | scripting/source/basprov/basscript.hxx | 29 |
1 files changed, 27 insertions, 2 deletions
diff --git a/scripting/source/basprov/basscript.hxx b/scripting/source/basprov/basscript.hxx index a524c186b2..12ac0a08eb 100644 --- a/scripting/source/basprov/basscript.hxx +++ b/scripting/source/basprov/basscript.hxx @@ -28,12 +28,14 @@ #ifndef SCRIPTING_BASSCRIPT_HXX #define SCRIPTING_BASSCRIPT_HXX +#include "bcholder.hxx" #include <com/sun/star/script/provider/XScript.hpp> #include <com/sun/star/document/XScriptInvocationContext.hpp> #include <cppuhelper/implbase1.hxx> +#include <comphelper/proparrhlp.hxx> +#include <comphelper/propertycontainer.hxx> #include <basic/sbmeth.hxx> - class BasicManager; //......................................................................... @@ -49,7 +51,11 @@ namespace basprov ::com::sun::star::script::provider::XScript > BasicScriptImpl_BASE; - class BasicScriptImpl : public BasicScriptImpl_BASE + class BasicScriptImpl : public BasicScriptImpl_BASE, + public ::scripting_helper::OMutexHolder, + public ::scripting_helper::OBroadcastHelperHolder, + public ::comphelper::OPropertyContainer, + public ::comphelper::OPropertyArrayUsageHelper< BasicScriptImpl > { private: SbMethodRef m_xMethod; @@ -57,6 +63,16 @@ namespace basprov BasicManager* m_documentBasicManager; ::com::sun::star::uno::Reference< ::com::sun::star::document::XScriptInvocationContext > m_xDocumentScriptContext; + // hack, OPropertyContainer doesn't allow you to define a property of unknown + // type ( I guess because an Any can't contain an Any... I've always wondered why? + // as its not unusual to do that in corba ) + ::com::sun::star::uno::Sequence< ::com::sun::star::uno::Any > m_caller; + protected: + // OPropertySetHelper + virtual ::cppu::IPropertyArrayHelper& SAL_CALL getInfoHelper( ); + + // OPropertyArrayUsageHelper + virtual ::cppu::IPropertyArrayHelper* createArrayHelper( ) const; public: BasicScriptImpl( @@ -71,6 +87,12 @@ namespace basprov ); virtual ~BasicScriptImpl(); + // XInterface + DECLARE_XINTERFACE() + + // XTypeProvider + DECLARE_XTYPEPROVIDER() + // XScript virtual ::com::sun::star::uno::Any SAL_CALL invoke( const ::com::sun::star::uno::Sequence< ::com::sun::star::uno::Any >& aParams, @@ -80,6 +102,9 @@ namespace basprov ::com::sun::star::script::provider::ScriptFrameworkErrorException, ::com::sun::star::reflection::InvocationTargetException, ::com::sun::star::uno::RuntimeException ); + // XPropertySet + virtual ::com::sun::star::uno::Reference< ::com::sun::star::beans::XPropertySetInfo > SAL_CALL getPropertySetInfo( ) + throw (::com::sun::star::uno::RuntimeException); }; //......................................................................... |