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_XMLSECURITY_SOURCE_FRAMEWORK_ELEMENTCOLLECTOR_HXX
21 #define INCLUDED_XMLSECURITY_SOURCE_FRAMEWORK_ELEMENTCOLLECTOR_HXX
23 #include "elementmark.hxx"
24 #include <com/sun/star/xml/crypto/sax/ElementMarkPriority.hpp>
25 #include <com/sun/star/uno/Reference.hxx>
27 namespace com::sun::star::xml::crypto::sax
{ class XReferenceResolvedListener
; }
29 class ElementCollector
: public ElementMark
30 /****** elementcollector.hxx/CLASS ElementCollector ***************************
33 * ElementCollector -- Class to manipulate an element collector
36 * This class is derived from the ElementMark class. Beyond the function
37 * of the ElementMark class, this class also maintains the priority, and
38 * manages the notify process
39 ******************************************************************************/
43 * the notify priority, is one of following values:
44 * AFTERMODIFY - this ElementCollector will notify after all
45 * internal modifications have finished.
46 * BEFOREMODIFY - this ElementCollector must notify before any
47 * internal modification happens.
49 css::xml::crypto::sax::ElementMarkPriority
const m_nPriority
;
52 * the modify flag, representing whether which elementcollector will
55 bool const m_bToModify
;
57 /* the notify enable flag, see notifyListener method */
60 /* whether the listener has been notified */
63 /* the listener to be notified */
64 css::uno::Reference
< css::xml::crypto::sax::XReferenceResolvedListener
> m_xReferenceResolvedListener
;
69 css::xml::crypto::sax::ElementMarkPriority nPriority
,
71 const css::uno::Reference
< css::xml::crypto::sax::XReferenceResolvedListener
>& xReferenceResolvedListener
);
73 css::xml::crypto::sax::ElementMarkPriority
getPriority() const { return m_nPriority
;}
74 bool getModify() const { return m_bToModify
;}
75 void notifyListener();
76 void setReferenceResolvedListener(
77 const css::uno::Reference
< css::xml::crypto::sax::XReferenceResolvedListener
>& referenceResolvedListener
);
83 /* vim:set shiftwidth=4 softtabstop=4 expandtab: */