Line data Source code
1 : /* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
2 : /*
3 : * This file is part of the LibreOffice project.
4 : *
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/.
8 : *
9 : * This file incorporates work covered by the following license notice:
10 : *
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 .
18 : */
19 :
20 : #ifndef INCLUDED_XMLOFF_SOURCE_TRANSFORM_DEEPTCONTEXT_HXX
21 : #define INCLUDED_XMLOFF_SOURCE_TRANSFORM_DEEPTCONTEXT_HXX
22 :
23 : #include <rtl/ref.hxx>
24 :
25 : #include <vector>
26 : #include "PersAttrListTContext.hxx"
27 : #include "TContextVector.hxx"
28 :
29 : class XMLPersElemContentTContext : public XMLPersAttrListTContext
30 : {
31 : XMLTransformerContextVector m_aChildContexts;
32 :
33 : public:
34 : TYPEINFO_OVERRIDE();
35 :
36 : // element content persistence only
37 : XMLPersElemContentTContext( XMLTransformerBase& rTransformer,
38 : const OUString& rQName );
39 :
40 : // element content persistence + attribute processing
41 : XMLPersElemContentTContext( XMLTransformerBase& rTransformer,
42 : const OUString& rQName,
43 : sal_uInt16 nActionMap );
44 :
45 : // element content persistence + renaming
46 : XMLPersElemContentTContext( XMLTransformerBase& rTransformer,
47 : const OUString& rQName,
48 : sal_uInt16 nPrefix,
49 : ::xmloff::token::XMLTokenEnum eToken );
50 :
51 : // element content persistence + renaming + attribute processing
52 : XMLPersElemContentTContext( XMLTransformerBase& rTransformer,
53 : const OUString& rQName,
54 : sal_uInt16 nPrefix,
55 : ::xmloff::token::XMLTokenEnum eToken,
56 : sal_uInt16 nActionMap );
57 :
58 : virtual ~XMLPersElemContentTContext();
59 :
60 : virtual XMLTransformerContext *CreateChildContext( sal_uInt16 nPrefix,
61 : const OUString& rLocalName,
62 : const OUString& rQName,
63 : const ::com::sun::star::uno::Reference< ::com::sun::star::xml::sax::XAttributeList >& xAttrList ) SAL_OVERRIDE;
64 :
65 : void AddContent( XMLTransformerContext *pContent );
66 :
67 2 : bool HasElementContent() const
68 : {
69 2 : return !m_aChildContexts.empty();
70 : }
71 :
72 : virtual void ExportContent() SAL_OVERRIDE;
73 : };
74 :
75 : #endif // INCLUDED_XMLOFF_SOURCE_TRANSFORM_DEEPTCONTEXT_HXX
76 :
77 : /* vim:set shiftwidth=4 softtabstop=4 expandtab: */
|