xref: /trunk/main/ucb/source/ucp/file/filprp.hxx (revision 91144cd0085a7583d2099b982122deb2184ab956)
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 _FILPRP_HXX_
24 #define _FILPRP_HXX_
25 
26 #include <ucbhelper/macros.hxx>
27 #include <cppuhelper/weak.hxx>
28 #include <com/sun/star/beans/XPropertySetInfo.hpp>
29 #include <com/sun/star/ucb/XContentProvider.hpp>
30 #include <com/sun/star/lang/XTypeProvider.hpp>
31 
32 
33 namespace fileaccess {
34 
35     class shell;
36 
37     class XPropertySetInfo_impl
38         : public cppu::OWeakObject,
39           public com::sun::star::lang::XTypeProvider,
40           public com::sun::star::beans::XPropertySetInfo
41     {
42     public:
43         XPropertySetInfo_impl( shell* pMyShell,const rtl::OUString& aUnqPath );
44         XPropertySetInfo_impl( shell* pMyShell,const com::sun::star::uno::Sequence< com::sun::star::beans::Property >& seq );
45 
46         virtual ~XPropertySetInfo_impl();
47 
48         // XInterface
49         virtual com::sun::star::uno::Any SAL_CALL
50         queryInterface(
51             const com::sun::star::uno::Type& aType );
52 
53         virtual void SAL_CALL
54         acquire(
55             void )
56             throw();
57 
58         virtual void SAL_CALL
59         release(
60             void )
61             throw();
62 
63 
64         // XTypeProvider
65 
66         XTYPEPROVIDER_DECL()
67 
68         virtual com::sun::star::uno::Sequence< com::sun::star::beans::Property > SAL_CALL
69         getProperties(
70             void );
71 
72         virtual com::sun::star::beans::Property SAL_CALL
73         getPropertyByName(
74             const rtl::OUString& aName );
75 
76         virtual sal_Bool SAL_CALL
77         hasPropertyByName( const rtl::OUString& Name );
78 
79     private:
80         shell*                                                                     m_pMyShell;
81         com::sun::star::uno::Reference< com::sun::star::ucb::XContentProvider >    m_xProvider;
82         sal_Int32                                                                  m_count;
83         com::sun::star::uno::Sequence< com::sun::star::beans::Property >           m_seq;
84     };
85 }
86 
87 #endif
88