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 __com_sun_star_document_XDocumentInfo_idl__ 24#define __com_sun_star_document_XDocumentInfo_idl__ 25 26#ifndef __com_sun_star_uno_XInterface_idl__ 27#include <com/sun/star/uno/XInterface.idl> 28#endif 29 30#ifndef __com_sun_star_lang_ArrayIndexOutOfBoundsException_idl__ 31#include <com/sun/star/lang/ArrayIndexOutOfBoundsException.idl> 32#endif 33 34//============================================================================= 35 36module com { module sun { module star { module document { 37 38//============================================================================= 39/** provides access to the user fields for the information regarding the 40 document 41 42 <p> 43 These fields are special one of the set of available document properties. 44 Other ones are accessed as properties (by using the interface 45 <type scope="com::sun::star::beans">XPropertySet</type>) of service 46 <type>DocumentInfo</type>. 47 </p> 48 49 @deprecated Use <type>XDocumentProperties</type> instead. 50 51 @see DocumentInfo 52 @see StandaloneDocumentInfo 53 @see com::sun::star::beans::XPropertySet 54 */ 55published interface XDocumentInfo: com::sun::star::uno::XInterface 56{ 57 //------------------------------------------------------------------------- 58 /** provides information about count of available fields 59 60 <p> 61 This count marks the top range of possible requests for get/set 62 any of these fields. Range = [0..count-1] 63 </p> 64 65 @returns 66 current count 67 */ 68 short getUserFieldCount(); 69 70 //------------------------------------------------------------------------- 71 /** returns the name of an user field 72 73 @param Index 74 specifies the position of requested field 75 Range = [0..count-1] 76 77 @returns 78 the name of the requested field 79 80 @throws com::sun::star::lang::ArrayIndexOutOfBoundsException 81 if <var>Index</var> don't fit range of [0..count-1] 82 */ 83 string getUserFieldName( [in] short Index ) 84 raises( com::sun::star::lang::ArrayIndexOutOfBoundsException ); 85 86 //------------------------------------------------------------------------- 87 /** returns the value of an user field 88 89 @param Index 90 specifies the position of requested field 91 Range = [0..count-1] 92 93 @returns 94 the value of the requested field 95 96 @throws com::sun::star::lang::ArrayIndexOutOfBoundsException 97 if <var>Index</var> don't fit range of [0..count-1] 98 */ 99 string getUserFieldValue( [in] short Index ) 100 raises( com::sun::star::lang::ArrayIndexOutOfBoundsException ); 101 102 //------------------------------------------------------------------------- 103 /** changes the name of one of the user fields 104 105 @param Index 106 specifies the position of requested field 107 Range = [0..count-1] 108 109 @param Name 110 the new name for this field to be set 111 112 @throws com::sun::star::lang::ArrayIndexOutOfBoundsException 113 if <var>Index</var> don't fit range of [0..count-1] 114 */ 115 void setUserFieldName( 116 [in] short Index , 117 [in] string Name ) 118 raises( com::sun::star::lang::ArrayIndexOutOfBoundsException ); 119 120 //------------------------------------------------------------------------- 121 /** changes the value of one of the user fields 122 123 @param Index 124 specifies the position of requested field 125 Range = [0..count-1] 126 127 @param Value 128 the new value for this field to be set 129 130 @throws com::sun::star::lang::ArrayIndexOutOfBoundsException 131 if <var>Index</var> don't fit range of [0..count-1] 132 */ 133 void setUserFieldValue( 134 [in] short Index , 135 [in] string Value ) 136 raises( com::sun::star::lang::ArrayIndexOutOfBoundsException ); 137}; 138 139//============================================================================= 140 141}; }; }; }; 142 143#endif 144