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 24#ifndef __com_sun_star_reflection_XTypeDescriptionEnumerationAccess_idl__ 25#define __com_sun_star_reflection_XTypeDescriptionEnumerationAccess_idl__ 26 27#ifndef __com_sun_star_uno_XInterface_idl__ 28#include <com/sun/star/uno/XInterface.idl> 29#endif 30#ifndef __com_sun_star_uno_TypeClass_idl__ 31#include <com/sun/star/uno/TypeClass.idl> 32#endif 33#ifndef __com_sun_star_reflection_XTypeDescriptionEnumeration_idl__ 34#include <com/sun/star/reflection/XTypeDescriptionEnumeration.idl> 35#endif 36#ifndef __com_sun_star_reflection_TypeDescriptionSearchDepth_idl__ 37#include <com/sun/star/reflection/TypeDescriptionSearchDepth.idl> 38#endif 39#ifndef __com_sun_star_reflection_NoSuchTypeNameException_idl__ 40#include <com/sun/star/reflection/NoSuchTypeNameException.idl> 41#endif 42#ifndef __com_sun_star_reflection_InvalidTypeNameException_idl__ 43#include <com/sun/star/reflection/InvalidTypeNameException.idl> 44#endif 45 46//============================================================================= 47 48 module com { module sun { module star { module reflection { 49 50//============================================================================= 51 52/** Defines an interface for creating enumerations for type descriptions. 53 54 @since OpenOffice 1.1.2 55 56 */ 57published interface XTypeDescriptionEnumerationAccess : com::sun::star::uno::XInterface 58{ 59 /** Creates an enumeration for type descriptions. 60 61 <p>An enumeration is always created for an UNOIDL module. The 62 enumeration contents can be restricted by specifying type classes. 63 Only types that match one of the supplied type classes will be part of 64 the collection. Additionally, it is possible to specify the depth 65 for the search within the underlying type description tree. 66 67 @param moduleName 68 contains the name of an UNOIDL module. Modules are seperated by a 69 single '.' (i.e., "com.sun.star.reflection"). The root of the module 70 hierarchy is specified with an empty string. Module names are always 71 absolute, never relative. 72 73 @param types 74 restricts the contents of the enumeration. It will only contain 75 type descriptions that match one of the supplied type classes. An 76 empty sequence specifies that the enumeration shall contain all 77 type descriptions. 78 79 <p>Valid types classes are: 80 <ul> 81 <li><member scope="com::sun::star::uno">TypeClass::MODULE</member> 82 <li><member scope="com::sun::star::uno">TypeClass::INTERFACE</member> 83 <li><member scope="com::sun::star::uno">TypeClass::SERVICE</member> 84 <li><member scope="com::sun::star::uno">TypeClass::STRUCT</member> 85 <li><member scope="com::sun::star::uno">TypeClass::ENUM</member> 86 <li><member scope="com::sun::star::uno">TypeClass::EXCEPTION</member> 87 <li><member scope="com::sun::star::uno">TypeClass::TYPEDEF</member> 88 <li><member scope="com::sun::star::uno">TypeClass::CONSTANT</member> 89 <li><member scope="com::sun::star::uno">TypeClass::CONSTANTS</member> 90 <li><member scope="com::sun::star::uno">TypeClass::SINGLETON</member> 91 </ul> 92 93 @param depth 94 specifies the depth of search in the underlying tree of type 95 descriptions. Clients should be aware of the fact that specifiying 96 <member>TypeDescriptionSearchDepth::INFINITE</member> can lead to 97 larger delays when constructing or using the 98 <type>XTypeDescriptionEnumeration</type> instance. 99 100 @returns 101 an enumeration of type descriptions. 102 103 <p>The enumeration returns implementations of 104 <type>XTypeDescription</type>. Following concrete UNOIDL parts 105 represented by specialized interfaces derived from 106 <type>XTypeDescription</type> can be returned by the enumerator: 107 108 <table border="1"> 109 <thead><tr><th>IDL</th><th>interface</th></tr></thead> 110 <tbody> 111 <tr> 112 <td>enum</td> 113 <td><type>XEnumTypeDescription</type></td> 114 </tr> 115 <tr> 116 <td>struct</td> 117 <td><type>XCompoundTypeDescription</type> (the returned 118 object should actually implement 119 <type>XStructTypeDescription</type>)</td> 120 </tr> 121 <tr> 122 <td>exception</td> 123 <td><type>XCompoundTypeDescription</type></td> 124 </tr> 125 <tr> 126 <td>interface</td> 127 <td><type>XInterfaceTypeDescription</type> (the returned 128 object should actually implement 129 <type>XInterfaceTypeDescription2</type>)</td> 130 </tr> 131 <tr> 132 <td>service</td> 133 <td><type>XServiceTypeDescription</type> (the returned 134 object should actually implement 135 <type>XServiceTypeDescription2</type>)</td> 136 </tr> 137 <tr> 138 <td>singleton</td> 139 <td><type>XSingletonTypeDescription</type> (the returned 140 object should actually implement 141 <type>XSingletonTypeDescription2</type>)</td> 142 </tr> 143 <tr> 144 <td>module</td> 145 <td><type>XModuleTypeDescription</type></td> 146 </tr> 147 <tr> 148 <td>typedef</td> 149 <td><type>XIndirectTypeDescription</type></td> 150 </tr> 151 <tr> 152 <td>constant</td> 153 <td><type>XConstantTypeDescription</type></td> 154 </tr> 155 <tr> 156 <td>constants</td> 157 <td><type>XConstantsTypeDescription</type></td> 158 </tr> 159 </tbody> 160 </table> 161 162 @throws NoSuchTypeNameException 163 in case that the given module name does not exist. This exception 164 will never be thrown in case moduleName is the empty string. 165 166 @throws InvalidTypeNameException 167 in case that the given module name does exist, but does not specify 168 an UNOIDL module. This exception will never be thrown in case 169 moduleName is the empty string. 170 */ 171 XTypeDescriptionEnumeration 172 createTypeDescriptionEnumeration( 173 [in] string moduleName, 174 [in] sequence< com::sun::star::uno::TypeClass > types, 175 [in] TypeDescriptionSearchDepth depth ) 176 raises( NoSuchTypeNameException, InvalidTypeNameException ); 177}; 178 179//============================================================================= 180 181}; }; }; }; 182 183#endif 184