1 /* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
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_SW_SOURCE_CORE_INC_UNOREFMARK_HXX
21 #define INCLUDED_SW_SOURCE_CORE_INC_UNOREFMARK_HXX
23 #include <com/sun/star/lang/XServiceInfo.hpp>
24 #include <com/sun/star/beans/XPropertySet.hpp>
25 #include <com/sun/star/container/XNamed.hpp>
26 #include <com/sun/star/text/XTextContent.hpp>
28 #include <cppuhelper/implbase.hxx>
30 #include <unobaseclass.hxx>
33 class SwFormatRefMark
;
35 typedef ::cppu::WeakImplHelper
36 < css::lang::XServiceInfo
37 , css::beans::XPropertySet
38 , css::container::XNamed
39 , css::text::XTextContent
40 > SwXReferenceMark_Base
;
42 class SwXReferenceMark final
43 : public SwXReferenceMark_Base
49 ::sw::UnoImplPtr
<Impl
> m_pImpl
;
51 virtual ~SwXReferenceMark() override
;
53 SwXReferenceMark(SwDoc
*const pDoc
, SwFormatRefMark
*const pMark
);
57 static rtl::Reference
<SwXReferenceMark
>
58 CreateXReferenceMark(SwDoc
& rDoc
, SwFormatRefMark
* pMarkFormat
);
61 virtual OUString SAL_CALL
getImplementationName() override
;
62 virtual sal_Bool SAL_CALL
supportsService(
63 const OUString
& rServiceName
) override
;
64 virtual css::uno::Sequence
< OUString
> SAL_CALL
65 getSupportedServiceNames() override
;
68 virtual void SAL_CALL
dispose() override
;
69 virtual void SAL_CALL
addEventListener(
70 const css::uno::Reference
< css::lang::XEventListener
> & xListener
) override
;
71 virtual void SAL_CALL
removeEventListener(
72 const css::uno::Reference
< css::lang::XEventListener
> & xListener
) override
;
75 virtual css::uno::Reference
< css::beans::XPropertySetInfo
> SAL_CALL
76 getPropertySetInfo() override
;
77 virtual void SAL_CALL
setPropertyValue(
78 const OUString
& rPropertyName
,
79 const css::uno::Any
& rValue
) override
;
80 virtual css::uno::Any SAL_CALL
getPropertyValue(
81 const OUString
& rPropertyName
) override
;
82 virtual void SAL_CALL
addPropertyChangeListener(
83 const OUString
& rPropertyName
,
84 const css::uno::Reference
< css::beans::XPropertyChangeListener
>& xListener
) override
;
85 virtual void SAL_CALL
removePropertyChangeListener(
86 const OUString
& rPropertyName
,
87 const css::uno::Reference
< css::beans::XPropertyChangeListener
>& xListener
) override
;
88 virtual void SAL_CALL
addVetoableChangeListener(
89 const OUString
& rPropertyName
,
90 const css::uno::Reference
< css::beans::XVetoableChangeListener
>& xListener
) override
;
91 virtual void SAL_CALL
removeVetoableChangeListener(
92 const OUString
& rPropertyName
,
93 const css::uno::Reference
< css::beans::XVetoableChangeListener
>& xListener
) override
;
96 virtual OUString SAL_CALL
getName() override
;
97 virtual void SAL_CALL
setName(const OUString
& rName
) override
;
100 virtual void SAL_CALL
attach(
101 const css::uno::Reference
< css::text::XTextRange
> & xTextRange
) override
;
102 virtual css::uno::Reference
< css::text::XTextRange
> SAL_CALL
getAnchor() override
;
106 #endif // INCLUDED_SW_SOURCE_CORE_INC_UNOREFMARK_HXX
108 /* vim:set shiftwidth=4 softtabstop=4 expandtab: */