LibreOffice
LibreOffice 24.8 SDK C/C++ API Reference
 
Loading...
Searching...
No Matches
typeprovider.hxx
Go to the documentation of this file.
1/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
2/*
3 * This file is part of the LibreOffice project.
4 *
5 * This Source Code Form is subject to the terms of the Mozilla Public
6 * License, v. 2.0. If a copy of the MPL was not distributed with this
7 * file, You can obtain one at http://mozilla.org/MPL/2.0/.
8 *
9 * This file incorporates work covered by the following license notice:
10 *
11 * Licensed to the Apache Software Foundation (ASF) under one or more
12 * contributor license agreements. See the NOTICE file distributed
13 * with this work for additional information regarding copyright
14 * ownership. The ASF licenses this file to you under the Apache
15 * License, Version 2.0 (the "License"); you may not use this file
16 * except in compliance with the License. You may obtain a copy of
17 * the License at http://www.apache.org/licenses/LICENSE-2.0 .
18 */
19
20/*
21 * This file is part of LibreOffice published API.
22 */
23#ifndef INCLUDED_CPPUHELPER_TYPEPROVIDER_HXX
24#define INCLUDED_CPPUHELPER_TYPEPROVIDER_HXX
25
26#include "sal/config.h"
27
28#include <cstddef>
29
30#include "rtl/alloc.h"
33
34
35namespace cppu
36{
37
42{
44
45public:
47 // these are here to force memory de/allocation to sal lib.
48 static void * SAL_CALL operator new( size_t nSize )
49 { return ::rtl_allocateMemory( nSize ); }
50 static void SAL_CALL operator delete( void * pMem )
51 { ::rtl_freeMemory( pMem ); }
52 static void * SAL_CALL operator new( size_t, void * pMem )
53 { return pMem; }
54 static void SAL_CALL operator delete( void *, void * )
55 {}
57
59 const css::uno::Type & rType1,
62 const css::uno::Type & rType1,
63 const css::uno::Type & rType2,
66 const css::uno::Type & rType1,
67 const css::uno::Type & rType2,
68 const css::uno::Type & rType3,
71 const css::uno::Type & rType1,
72 const css::uno::Type & rType2,
73 const css::uno::Type & rType3,
74 const css::uno::Type & rType4,
77 const css::uno::Type & rType1,
78 const css::uno::Type & rType2,
79 const css::uno::Type & rType3,
80 const css::uno::Type & rType4,
81 const css::uno::Type & rType5,
84 const css::uno::Type & rType1,
85 const css::uno::Type & rType2,
86 const css::uno::Type & rType3,
87 const css::uno::Type & rType4,
88 const css::uno::Type & rType5,
89 const css::uno::Type & rType6,
92 const css::uno::Type & rType1,
93 const css::uno::Type & rType2,
94 const css::uno::Type & rType3,
95 const css::uno::Type & rType4,
96 const css::uno::Type & rType5,
97 const css::uno::Type & rType6,
98 const css::uno::Type & rType7,
101 const css::uno::Type & rType1,
102 const css::uno::Type & rType2,
103 const css::uno::Type & rType3,
104 const css::uno::Type & rType4,
105 const css::uno::Type & rType5,
106 const css::uno::Type & rType6,
107 const css::uno::Type & rType7,
108 const css::uno::Type & rType8,
111 const css::uno::Type & rType1,
112 const css::uno::Type & rType2,
113 const css::uno::Type & rType3,
114 const css::uno::Type & rType4,
115 const css::uno::Type & rType5,
116 const css::uno::Type & rType6,
117 const css::uno::Type & rType7,
118 const css::uno::Type & rType8,
119 const css::uno::Type & rType9,
122 const css::uno::Type & rType1,
123 const css::uno::Type & rType2,
124 const css::uno::Type & rType3,
125 const css::uno::Type & rType4,
126 const css::uno::Type & rType5,
127 const css::uno::Type & rType6,
128 const css::uno::Type & rType7,
129 const css::uno::Type & rType8,
130 const css::uno::Type & rType9,
131 const css::uno::Type & rType10,
134 const css::uno::Type & rType1,
135 const css::uno::Type & rType2,
136 const css::uno::Type & rType3,
137 const css::uno::Type & rType4,
138 const css::uno::Type & rType5,
139 const css::uno::Type & rType6,
140 const css::uno::Type & rType7,
141 const css::uno::Type & rType8,
142 const css::uno::Type & rType9,
143 const css::uno::Type & rType10,
144 const css::uno::Type & rType11,
147 const css::uno::Type & rType1,
148 const css::uno::Type & rType2,
149 const css::uno::Type & rType3,
150 const css::uno::Type & rType4,
151 const css::uno::Type & rType5,
152 const css::uno::Type & rType6,
153 const css::uno::Type & rType7,
154 const css::uno::Type & rType8,
155 const css::uno::Type & rType9,
156 const css::uno::Type & rType10,
157 const css::uno::Type & rType11,
158 const css::uno::Type & rType12,
160
166 { return _aTypes; }
167#if defined LIBO_INTERNAL_ONLY
168 css::uno::Sequence< css::uno::Type > const & getTypes() const
169 { return _aTypes; }
170#endif
171};
172
176class SAL_DEPRECATED("Uses broken double checked locking") SAL_WARN_UNUSED CPPUHELPER_DLLPUBLIC OImplementationId
177{
178 mutable css::uno::Sequence< sal_Int8 > * _pSeq;
179 sal_Bool _bUseEthernetAddress;
180
181public:
183
184 // these are here to force memory de/allocation to sal lib.
185 static void * SAL_CALL operator new( size_t nSize )
186 { return ::rtl_allocateMemory( nSize ); }
187 static void SAL_CALL operator delete( void * pMem )
188 { ::rtl_freeMemory( pMem ); }
189 static void * SAL_CALL operator new( size_t, void * pMem )
190 { return pMem; }
191 static void SAL_CALL operator delete( void *, void * )
192 {}
193
195
197
202 OImplementationId( bool bUseEthernetAddress = true )
203 : _pSeq( NULL )
204 , _bUseEthernetAddress( bUseEthernetAddress )
205 {}
206
211 : _pSeq( new css::uno::Sequence< sal_Int8 >( rSeq ) )
212 , _bUseEthernetAddress( false )
213 {}
216 : _pSeq( new css::uno::Sequence< sal_Int8 >( rId.getImplementationId() ) )
217 , _bUseEthernetAddress( false )
218 {}
220
226};
227
228}
229
230#endif
231
232/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
#define SAL_DEPRECATED(message)
Use as follows: SAL_DEPRECATED("Don't use, it's evil.") void doit(int nPara);.
Definition types.h:492
#define SAL_WNODEPRECATED_DECLARATIONS_POP
Definition types.h:533
unsigned char sal_Bool
Definition types.h:38
signed char sal_Int8
Definition types.h:43
#define SAL_WNODEPRECATED_DECLARATIONS_PUSH
Use as follows: SAL_WNODEPRECATED_DECLARATIONS_PUSH ::std::auto_ptr<X> ... SAL_WNODEPRECATED_DECLARAT...
Definition types.h:532
#define SAL_WARN_UNUSED
Annotate classes where a compiler should warn if an instance is unused.
Definition types.h:611
SAL_DLLPUBLIC void rtl_freeMemory(void *Ptr) SAL_THROW_EXTERN_C()
Free memory.
#define CPPUHELPER_DLLPUBLIC
Definition cppuhelperdllapi.h:32
Definition types.h:377
Definition Enterable.hxx:31
Template C++ class representing an IDL sequence.
Definition Sequence.h:61
OTypeCollection(const css::uno::Type &rType1, const css::uno::Type &rType2, const css::uno::Sequence< css::uno::Type > &rAddTypes=css::uno::Sequence< css::uno::Type >())
OTypeCollection(const css::uno::Type &rType1, const css::uno::Type &rType2, const css::uno::Type &rType3, const css::uno::Type &rType4, const css::uno::Type &rType5, const css::uno::Type &rType6, const css::uno::Type &rType7, const css::uno::Type &rType8, const css::uno::Type &rType9, const css::uno::Type &rType10, const css::uno::Type &rType11, const css::uno::Type &rType12, const css::uno::Sequence< css::uno::Type > &rAddTypes=css::uno::Sequence< css::uno::Type >())
OTypeCollection(const css::uno::Type &rType1, const css::uno::Type &rType2, const css::uno::Type &rType3, const css::uno::Type &rType4, const css::uno::Type &rType5, const css::uno::Type &rType6, const css::uno::Sequence< css::uno::Type > &rAddTypes=css::uno::Sequence< css::uno::Type >())
OTypeCollection(const css::uno::Type &rType1, const css::uno::Type &rType2, const css::uno::Type &rType3, const css::uno::Type &rType4, const css::uno::Type &rType5, const css::uno::Type &rType6, const css::uno::Type &rType7, const css::uno::Type &rType8, const css::uno::Type &rType9, const css::uno::Type &rType10, const css::uno::Sequence< css::uno::Type > &rAddTypes=css::uno::Sequence< css::uno::Type >())
css::uno::Sequence< css::uno::Type > getTypes()
Called upon XTypeProvider::getTypes().
Definition typeprovider.hxx:165
OTypeCollection(const css::uno::Type &rType1, const css::uno::Type &rType2, const css::uno::Type &rType3, const css::uno::Type &rType4, const css::uno::Type &rType5, const css::uno::Sequence< css::uno::Type > &rAddTypes=css::uno::Sequence< css::uno::Type >())
OTypeCollection(const css::uno::Type &rType1, const css::uno::Type &rType2, const css::uno::Type &rType3, const css::uno::Type &rType4, const css::uno::Sequence< css::uno::Type > &rAddTypes=css::uno::Sequence< css::uno::Type >())
OTypeCollection(const css::uno::Type &rType1, const css::uno::Type &rType2, const css::uno::Type &rType3, const css::uno::Sequence< css::uno::Type > &rAddTypes=css::uno::Sequence< css::uno::Type >())
OTypeCollection(const css::uno::Type &rType1, const css::uno::Type &rType2, const css::uno::Type &rType3, const css::uno::Type &rType4, const css::uno::Type &rType5, const css::uno::Type &rType6, const css::uno::Type &rType7, const css::uno::Type &rType8, const css::uno::Sequence< css::uno::Type > &rAddTypes=css::uno::Sequence< css::uno::Type >())
OTypeCollection(const css::uno::Type &rType1, const css::uno::Type &rType2, const css::uno::Type &rType3, const css::uno::Type &rType4, const css::uno::Type &rType5, const css::uno::Type &rType6, const css::uno::Type &rType7, const css::uno::Sequence< css::uno::Type > &rAddTypes=css::uno::Sequence< css::uno::Type >())
OTypeCollection(const css::uno::Type &rType1, const css::uno::Type &rType2, const css::uno::Type &rType3, const css::uno::Type &rType4, const css::uno::Type &rType5, const css::uno::Type &rType6, const css::uno::Type &rType7, const css::uno::Type &rType8, const css::uno::Type &rType9, const css::uno::Sequence< css::uno::Type > &rAddTypes=css::uno::Sequence< css::uno::Type >())
OTypeCollection(const css::uno::Type &rType1, const css::uno::Sequence< css::uno::Type > &rAddTypes=css::uno::Sequence< css::uno::Type >())
OTypeCollection(const css::uno::Type &rType1, const css::uno::Type &rType2, const css::uno::Type &rType3, const css::uno::Type &rType4, const css::uno::Type &rType5, const css::uno::Type &rType6, const css::uno::Type &rType7, const css::uno::Type &rType8, const css::uno::Type &rType9, const css::uno::Type &rType10, const css::uno::Type &rType11, const css::uno::Sequence< css::uno::Type > &rAddTypes=css::uno::Sequence< css::uno::Type >())
OImplementationId(bool bUseEthernetAddress=true)
Constructor.
Definition typeprovider.hxx:202
SAL_WNODEPRECATED_DECLARATIONS_PUSH OImplementationId(const OImplementationId &rId)
Definition typeprovider.hxx:215
OImplementationId(const css::uno::Sequence< sal_Int8 > &rSeq)
Constructor giving implementation id.
Definition typeprovider.hxx:210
SAL_WNODEPRECATED_DECLARATIONS_POP css::uno::Sequence< sal_Int8 > getImplementationId() const
Get implementation id.
C++ class representing an IDL meta type.
Definition Type.h:59