Bump for 3.6-28
[LibreOffice.git] / xmloff / source / transform / IgnoreTContext.hxx
blob71d390dd0748e6c32745419a9bea1c9feaac2ae3
1 /* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
2 /*************************************************************************
4 * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
6 * Copyright 2000, 2010 Oracle and/or its affiliates.
8 * OpenOffice.org - a multi-platform office productivity suite
10 * This file is part of OpenOffice.org.
12 * OpenOffice.org is free software: you can redistribute it and/or modify
13 * it under the terms of the GNU Lesser General Public License version 3
14 * only, as published by the Free Software Foundation.
16 * OpenOffice.org is distributed in the hope that it will be useful,
17 * but WITHOUT ANY WARRANTY; without even the implied warranty of
18 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
19 * GNU Lesser General Public License version 3 for more details
20 * (a copy is included in the LICENSE file that accompanied this code).
22 * You should have received a copy of the GNU Lesser General Public License
23 * version 3 along with OpenOffice.org. If not, see
24 * <http://www.openoffice.org/license.html>
25 * for a copy of the LGPLv3 License.
27 ************************************************************************/
29 #ifndef _XMLOFF_IGNORETCONTEXT_HXX
30 #define _XMLOFF_IGNORETCONTEXT_HXX
32 #include "TransformerContext.hxx"
35 class XMLIgnoreTransformerContext : public XMLTransformerContext
37 sal_Bool m_bIgnoreCharacters;
38 sal_Bool m_bIgnoreElements;
39 sal_Bool m_bAllowCharactersRecursive;
40 sal_Bool m_bRecursiveUse;
42 public:
43 TYPEINFO();
45 // A contexts constructor does anything that is required if an element
46 // starts. Namespace processing has been done already.
47 // Note that virtual methods cannot be used inside constructors. Use
48 // StartElement instead if this is required.
49 XMLIgnoreTransformerContext( XMLTransformerBase& rTransformer,
50 const ::rtl::OUString& rQName,
51 sal_Bool bIgnoreCharacters,
52 sal_Bool bIgnoreElements );
53 // A contexts constructor does anything that is required if an element
54 // starts. Namespace processing has been done already.
55 // Note that virtual methods cannot be used inside constructors. Use
56 // StartElement instead if this is required.
57 XMLIgnoreTransformerContext( XMLTransformerBase& rTransformer,
58 const ::rtl::OUString& rQName,
59 sal_Bool bAllowCharactersRecursive );
61 // A contexts destructor does anything that is required if an element
62 // ends. By default, nothing is done.
63 // Note that virtual methods cannot be used inside destructors. Use
64 // EndElement instead if this is required.
65 virtual ~XMLIgnoreTransformerContext();
67 // Create a children element context. By default, the import's
68 // CreateContext method is called to create a new default context.
69 virtual XMLTransformerContext *CreateChildContext( sal_uInt16 nPrefix,
70 const ::rtl::OUString& rLocalName,
71 const ::rtl::OUString& rQName,
72 const ::com::sun::star::uno::Reference< ::com::sun::star::xml::sax::XAttributeList >& xAttrList );
74 // StartElement is called after a context has been constructed and
75 // before a elements context is parsed. It may be used for actions that
76 // require virtual methods. The default is to do nothing.
77 virtual void StartElement( const ::com::sun::star::uno::Reference< ::com::sun::star::xml::sax::XAttributeList >& xAttrList );
79 // EndElement is called before a context will be destructed, but
80 // after a elements context has been parsed. It may be used for actions
81 // that require virtual methods. The default is to do nothing.
82 virtual void EndElement();
84 // This method is called for all characters that are contained in the
85 // current element. The default is to ignore them.
86 virtual void Characters( const ::rtl::OUString& rChars );
89 #endif // _XMLOFF_IGNORETCONTEXT_HXX
91 /* vim:set shiftwidth=4 softtabstop=4 expandtab: */