1/************************************************************************* 2 * 3 * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. 4 * 5 * Copyright 2000, 2010 Oracle and/or its affiliates. 6 * 7 * OpenOffice.org - a multi-platform office productivity suite 8 * 9 * This file is part of OpenOffice.org. 10 * 11 * OpenOffice.org is free software: you can redistribute it and/or modify 12 * it under the terms of the GNU Lesser General Public License version 3 13 * only, as published by the Free Software Foundation. 14 * 15 * OpenOffice.org is distributed in the hope that it will be useful, 16 * but WITHOUT ANY WARRANTY; without even the implied warranty of 17 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 18 * GNU Lesser General Public License version 3 for more details 19 * (a copy is included in the LICENSE file that accompanied this code). 20 * 21 * You should have received a copy of the GNU Lesser General Public License 22 * version 3 along with OpenOffice.org. If not, see 23 * <http://www.openoffice.org/license.html> 24 * for a copy of the LGPLv3 License. 25 * 26 ************************************************************************/ 27#ifndef __com_sun_star_util_XSortable_idl__ 28#define __com_sun_star_util_XSortable_idl__ 29 30#ifndef __com_sun_star_uno_XInterface_idl__ 31#include <com/sun/star/uno/XInterface.idl> 32#endif 33 34#ifndef __com_sun_star_beans_PropertyValue_idl__ 35#include <com/sun/star/beans/PropertyValue.idl> 36#endif 37 38 39//============================================================================= 40 41module com { module sun { module star { module util { 42 43//============================================================================= 44 45/** makes it possible to sort the contents of this object. 46 47 <p>The available properties describing the sort criterias are 48 defined in the sort descriptor implemented by the object that 49 implements this interface.</p> 50 51 <p>There are older deprecated sort descriptors:</p> 52 <ul> 53 <li>com::sun::star::util::SortDescriptor</li> 54 <li>com::sun::star::table::TableSortDescriptor</li> 55 <li>com::sun::star::text::TextSortDescriptor</li> 56 </ul> 57 58 <p>And a new set of sort descriptors:</p> 59 <ul> 60 <li>com::sun::star::util::SortDescriptor2</li> 61 <li>com::sun::star::table::TableSortDescriptor2</li> 62 <li>com::sun::star::text::TextSortDescriptor2</li> 63 </ul> 64 65 <p>Both types may be implemented by the same object. 66 When calling the sort method however properties from different 67 descriptors must not be mixed.</p> 68 */ 69published interface XSortable: com::sun::star::uno::XInterface 70{ 71 //------------------------------------------------------------------------- 72 /** @returns 73 a sequence of properties which allows to specify/modify the 74 sort criteria. 75 76 <p>The set of properties is specific to the type of object that 77 implements this interface. Therefore they can usually be used 78 only for objects of that same type.</p> 79 80 @see com::sun::star::util::SortDescriptor 81 @see com::sun::star::table::TableSortDescriptor 82 @see com::sun::star::text::TextSortDescriptor 83 @see com::sun::star::util::SortDescriptor2 84 @see com::sun::star::table::TableSortDescriptor2 85 @see com::sun::star::text::TextSortDescriptor2 86 87 */ 88 sequence< com::sun::star::beans::PropertyValue > createSortDescriptor(); 89 90 //------------------------------------------------------------------------- 91 /** sorts the contents of the object according to the specified 92 properties. 93 94 <p>The specified properties are usually the same or a subset of 95 those obtained by calling <member>createSortDescriptor</member> 96 on the same type of object.<p> 97 98 @see com::sun::star::util::SortDescriptor 99 @see com::sun::star::table::TableSortDescriptor 100 @see com::sun::star::text::TextSortDescriptor 101 @see com::sun::star::util::SortDescriptor2 102 @see com::sun::star::table::TableSortDescriptor2 103 @see com::sun::star::text::TextSortDescriptor2 104 */ 105 void sort( [in] sequence< com::sun::star::beans::PropertyValue > xDescriptor ); 106 107}; 108 109//============================================================================= 110 111}; }; }; }; 112 113#endif 114