Update git submodules
[LibreOffice.git] / include / unotools / collatorwrapper.hxx
blob595d9ccf4f41e158f20445a0b04ed02ef2b542ed
1 /* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
2 /*
3 * This file is part of the LibreOffice project.
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/.
9 * This file incorporates work covered by the following license notice:
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 .
20 #ifndef INCLUDED_UNOTOOLS_COLLATORWRAPPER_HXX
21 #define INCLUDED_UNOTOOLS_COLLATORWRAPPER_HXX
23 #include <unotools/unotoolsdllapi.h>
24 #include <com/sun/star/uno/Reference.hxx>
25 #include <com/sun/star/uno/Sequence.hxx>
27 namespace com::sun::star::uno {
28 class XComponentContext;
31 namespace com::sun::star::i18n { class XCollator; }
32 namespace com::sun::star::lang { struct Locale; }
34 class UNOTOOLS_DLLPUBLIC CollatorWrapper
36 private:
37 css::uno::Reference< css::i18n::XCollator > mxInternationalCollator;
39 public:
41 CollatorWrapper (
42 const css::uno::Reference< css::uno::XComponentContext > &rxContext);
44 sal_Int32
45 compareString (
46 const OUString& s1, const OUString& s2) const;
48 css::uno::Sequence< OUString >
49 listCollatorAlgorithms (
50 const css::lang::Locale& rLocale) const;
52 sal_Int32
53 loadDefaultCollator (
54 const css::lang::Locale& rLocale, sal_Int32 nOption);
56 void
57 loadCollatorAlgorithm (
58 const OUString& rAlgorithm,
59 const css::lang::Locale& rLocale, sal_Int32 nOption);
62 #endif // INCLUDED_UNOTOOLS_COLLATORWRAPPER_HXX
64 /* vim:set shiftwidth=4 softtabstop=4 expandtab: */