bump product version to 4.1.6.2
[LibreOffice.git] / unoxml / source / events / mutationevent.hxx
blob8687233f6d37a92961980b2d3f688559cd387615
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 EVENT_MUTATIONEVENT_HXX
21 #define EVENT_MUTATIONEVENT_HXX
23 #include <sal/types.h>
25 #include <com/sun/star/uno/Reference.h>
27 #include <com/sun/star/xml/dom/events/PhaseType.hpp>
28 #include <com/sun/star/xml/dom/events/AttrChangeType.hpp>
29 #include <com/sun/star/xml/dom/events/XMutationEvent.hpp>
31 #include <cppuhelper/implbase1.hxx>
33 #include "event.hxx"
35 namespace DOM { namespace events {
37 typedef ::cppu::ImplInheritanceHelper1< CEvent, XMutationEvent >
38 CMutationEvent_Base;
40 class CMutationEvent
41 : public CMutationEvent_Base
43 protected:
44 Reference< XNode > m_relatedNode;
45 OUString m_prevValue;
46 OUString m_newValue;
47 OUString m_attrName;
48 AttrChangeType m_attrChangeType;
50 public:
51 explicit CMutationEvent();
53 virtual ~CMutationEvent();
55 virtual Reference< XNode > SAL_CALL getRelatedNode() throw (RuntimeException);
56 virtual OUString SAL_CALL getPrevValue() throw (RuntimeException);
57 virtual OUString SAL_CALL getNewValue() throw (RuntimeException);
58 virtual OUString SAL_CALL getAttrName() throw (RuntimeException);
59 virtual AttrChangeType SAL_CALL getAttrChange() throw (RuntimeException);
60 virtual void SAL_CALL initMutationEvent(
61 const OUString& typeArg,
62 sal_Bool canBubbleArg,
63 sal_Bool cancelableArg,
64 const Reference< XNode >& relatedNodeArg,
65 const OUString& prevValueArg,
66 const OUString& newValueArg,
67 const OUString& attrNameArg,
68 AttrChangeType attrChangeArg) throw (RuntimeException);
70 // delegate to CEvent, since we are inheriting from CEvent and XEvent
71 virtual OUString SAL_CALL getType() throw (RuntimeException);
72 virtual Reference< XEventTarget > SAL_CALL getTarget() throw (RuntimeException);
73 virtual Reference< XEventTarget > SAL_CALL getCurrentTarget() throw (RuntimeException);
74 virtual PhaseType SAL_CALL getEventPhase() throw (RuntimeException);
75 virtual sal_Bool SAL_CALL getBubbles() throw (RuntimeException);
76 virtual sal_Bool SAL_CALL getCancelable() throw (RuntimeException);
77 virtual com::sun::star::util::Time SAL_CALL getTimeStamp() throw (RuntimeException);
78 virtual void SAL_CALL stopPropagation() throw (RuntimeException);
79 virtual void SAL_CALL preventDefault() throw (RuntimeException);
80 virtual void SAL_CALL initEvent(
81 const OUString& eventTypeArg,
82 sal_Bool canBubbleArg,
83 sal_Bool cancelableArg)
84 throw (RuntimeException);
87 #endif
89 /* vim:set shiftwidth=4 softtabstop=4 expandtab: */