Line data Source code
1 : #ifndef INCLUDED_COM_SUN_STAR_LANG_DISPOSEDEXCEPTION_HPP
2 : #define INCLUDED_COM_SUN_STAR_LANG_DISPOSEDEXCEPTION_HPP
3 :
4 : #include "sal/config.h"
5 :
6 : #include "com/sun/star/lang/DisposedException.hdl"
7 :
8 : #include "com/sun/star/uno/RuntimeException.hpp"
9 : #include "com/sun/star/uno/Type.hxx"
10 : #include "cppu/unotype.hxx"
11 : #include "osl/mutex.hxx"
12 : #include "rtl/instance.hxx"
13 :
14 : namespace com { namespace sun { namespace star { namespace lang {
15 :
16 372 : inline DisposedException::DisposedException() SAL_THROW(())
17 372 : : css::uno::RuntimeException()
18 : {
19 372 : ::cppu::UnoType< css::lang::DisposedException >::get();
20 372 : }
21 :
22 2598 : inline DisposedException::DisposedException(const ::rtl::OUString& Message_, const ::com::sun::star::uno::Reference< css::uno::XInterface >& Context_) SAL_THROW(())
23 2598 : : css::uno::RuntimeException(Message_, Context_)
24 : {
25 2598 : ::cppu::UnoType< css::lang::DisposedException >::get();
26 2598 : }
27 :
28 0 : DisposedException::DisposedException(DisposedException const & the_other): css::uno::RuntimeException(the_other) {}
29 :
30 2970 : DisposedException::~DisposedException() {}
31 :
32 : DisposedException & DisposedException::operator =(DisposedException const & the_other) {
33 : //TODO: Just like its implicitly-defined counterpart, this function definition is not exception-safe
34 : css::uno::RuntimeException::operator =(the_other);
35 : return *this;
36 : }
37 :
38 : } } } }
39 :
40 : namespace com { namespace sun { namespace star { namespace lang { namespace detail {
41 :
42 : struct theDisposedExceptionType : public rtl::StaticWithInit< ::com::sun::star::uno::Type *, theDisposedExceptionType >
43 : {
44 87 : ::com::sun::star::uno::Type * operator()() const
45 : {
46 87 : ::rtl::OUString sTypeName( "com.sun.star.lang.DisposedException" );
47 :
48 : // Start inline typedescription generation
49 87 : typelib_TypeDescription * pTD = 0;
50 87 : const ::com::sun::star::uno::Type& rSuperType = ::cppu::UnoType< css::uno::RuntimeException >::get();
51 :
52 : typelib_typedescription_new(
53 : &pTD,
54 : (typelib_TypeClass)::com::sun::star::uno::TypeClass_EXCEPTION, sTypeName.pData,
55 : rSuperType.getTypeLibType(),
56 : 0,
57 87 : 0 );
58 :
59 87 : typelib_typedescription_register( (typelib_TypeDescription**)&pTD );
60 :
61 87 : typelib_typedescription_release( pTD );
62 : // End inline typedescription generation
63 :
64 87 : return new ::com::sun::star::uno::Type( ::com::sun::star::uno::TypeClass_EXCEPTION, sTypeName ); // leaked
65 : }
66 : };
67 :
68 : } } } } }
69 :
70 : namespace com { namespace sun { namespace star { namespace lang {
71 :
72 2970 : inline ::com::sun::star::uno::Type const & cppu_detail_getUnoType(SAL_UNUSED_PARAMETER css::lang::DisposedException const *) {
73 2970 : return *detail::theDisposedExceptionType::get();
74 : }
75 :
76 : } } } }
77 :
78 : inline ::com::sun::star::uno::Type const & SAL_CALL getCppuType(SAL_UNUSED_PARAMETER css::lang::DisposedException const *) SAL_THROW(()) {
79 : return ::cppu::UnoType< css::lang::DisposedException >::get();
80 : }
81 :
82 : #endif // INCLUDED_COM_SUN_STAR_LANG_DISPOSEDEXCEPTION_HPP
|