1 /**************************************************************
2  *
3  * Licensed to the Apache Software Foundation (ASF) under one
4  * or more contributor license agreements.  See the NOTICE file
5  * distributed with this work for additional information
6  * regarding copyright ownership.  The ASF licenses this file
7  * to you under the Apache License, Version 2.0 (the
8  * "License"); you may not use this file except in compliance
9  * with the License.  You may obtain a copy of the License at
10  *
11  *   http://www.apache.org/licenses/LICENSE-2.0
12  *
13  * Unless required by applicable law or agreed to in writing,
14  * software distributed under the License is distributed on an
15  * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
16  * KIND, either express or implied.  See the License for the
17  * specific language governing permissions and limitations
18  * under the License.
19  *
20  *************************************************************/
21 
22 
23 #ifndef CHART_WALLFLOORWRAPPER_HXX
24 #define CHART_WALLFLOORWRAPPER_HXX
25 
26 #include "WrappedPropertySet.hxx"
27 #include "ServiceMacros.hxx"
28 #include <cppuhelper/implbase2.hxx>
29 #include <comphelper/uno3.hxx>
30 #include <cppuhelper/interfacecontainer.hxx>
31 #include <com/sun/star/lang/XComponent.hpp>
32 #include <com/sun/star/lang/XServiceInfo.hpp>
33 #include <com/sun/star/uno/XComponentContext.hpp>
34 
35 #include <boost/shared_ptr.hpp>
36 
37 namespace chart
38 {
39 
40 namespace wrapper
41 {
42 
43 class Chart2ModelContact;
44 
45 class WallFloorWrapper : public ::cppu::ImplInheritanceHelper2<
46                       WrappedPropertySet
47                     , com::sun::star::lang::XComponent
48                     , com::sun::star::lang::XServiceInfo
49                     >
50 {
51 public:
52     WallFloorWrapper( bool bWall, ::boost::shared_ptr< Chart2ModelContact > spChart2ModelContact );
53 	virtual ~WallFloorWrapper();
54 
55     /// XServiceInfo declarations
56     APPHELPER_XSERVICEINFO_DECL()
57 
58     // ____ XComponent ____
59     virtual void SAL_CALL dispose()
60         throw (::com::sun::star::uno::RuntimeException);
61     virtual void SAL_CALL addEventListener( const ::com::sun::star::uno::Reference<
62                                             ::com::sun::star::lang::XEventListener >& xListener )
63         throw (::com::sun::star::uno::RuntimeException);
64     virtual void SAL_CALL removeEventListener( const ::com::sun::star::uno::Reference<
65                                                ::com::sun::star::lang::XEventListener >& aListener )
66         throw (::com::sun::star::uno::RuntimeException);
67 
68 protected:
69     // ____ WrappedPropertySet ____
70     virtual const ::com::sun::star::uno::Sequence< ::com::sun::star::beans::Property >& getPropertySequence();
71     virtual const std::vector< WrappedProperty* > createWrappedProperties();
72     virtual ::com::sun::star::uno::Reference< ::com::sun::star::beans::XPropertySet > getInnerPropertySet();
73 
74 private:
75     ::boost::shared_ptr< Chart2ModelContact >   m_spChart2ModelContact;
76 	::cppu::OInterfaceContainerHelper           m_aEventListenerContainer;
77 
78     bool m_bWall;
79 };
80 
81 } //  namespace wrapper
82 } //  namespace chart
83 
84 // CHART_WALLFLOORWRAPPER_HXX
85 #endif
86