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 _LINGUISTIC_THESDTA_HXX_ 25 #define _LINGUISTIC_THESDTA_HXX_ 26 27 28 #include <com/sun/star/linguistic2/XMeaning.hpp> 29 30 #include <tools/solar.h> 31 32 #include <uno/lbnames.h> // CPPU_CURRENT_LANGUAGE_BINDING_NAME macro, which specify the environment type 33 #include <cppuhelper/implbase1.hxx> // helper for implementations 34 35 36 namespace linguistic 37 { 38 39 class Meaning : 40 public cppu::WeakImplHelper1 41 < 42 ::com::sun::star::linguistic2::XMeaning 43 > 44 { 45 ::com::sun::star::uno::Sequence< ::rtl::OUString > aSyn; // list of synonyms, may be empty. 46 ::rtl::OUString aTerm; 47 sal_Int16 nLanguage; 48 49 #if 0 50 // this is for future use by a German thesaurus 51 sal_Bool bIsGermanPreReform; 52 #endif 53 54 // disallow copy-constructor and assignment-operator for now 55 Meaning(const Meaning &); 56 Meaning & operator = (const Meaning &); 57 58 public: 59 #if 0 60 Meaning(const ::rtl::OUString &rTerm, sal_Int16 nLang, const PropertyHelper_Thes &rHelper); 61 #else 62 Meaning(const ::rtl::OUString &rTerm, sal_Int16 nLang); 63 #endif 64 virtual ~Meaning(); 65 66 // XMeaning 67 virtual ::rtl::OUString SAL_CALL getMeaning() throw(::com::sun::star::uno::RuntimeException); 68 virtual ::com::sun::star::uno::Sequence< ::rtl::OUString > SAL_CALL querySynonyms() throw(::com::sun::star::uno::RuntimeException); 69 70 // non-interface specific functions 71 void SetSynonyms( const ::com::sun::star::uno::Sequence< ::rtl::OUString > &rSyn ); 72 void SetMeaning( const ::rtl::OUString &rTerm ); 73 }; 74 75 76 /////////////////////////////////////////////////////////////////////////// 77 78 } // namespace linguistic 79 80 #endif 81 82 83