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 : #include "oox/core/contexthandler.hxx"
21 :
22 : #include "oox/core/fragmenthandler.hxx"
23 :
24 : namespace oox {
25 : namespace core {
26 :
27 : using namespace ::com::sun::star::uno;
28 : using namespace ::com::sun::star::xml::sax;
29 :
30 424596 : ContextHandler::ContextHandler( const ContextHandler& rParent ) :
31 : ContextHandler_BASE(),
32 424596 : mxBaseData( rParent.mxBaseData )
33 : {
34 424596 : }
35 :
36 19918 : ContextHandler::ContextHandler( const FragmentBaseDataRef& rxBaseData ) :
37 19918 : mxBaseData( rxBaseData )
38 : {
39 19918 : }
40 :
41 444514 : ContextHandler::~ContextHandler()
42 : {
43 444514 : }
44 :
45 39952 : XmlFilterBase& ContextHandler::getFilter() const
46 : {
47 39952 : return mxBaseData->mrFilter;
48 : }
49 :
50 1224 : const Relations& ContextHandler::getRelations() const
51 : {
52 1224 : return *mxBaseData->mxRelations;
53 : }
54 :
55 24934 : const OUString& ContextHandler::getFragmentPath() const
56 : {
57 24934 : return mxBaseData->maFragmentPath;
58 : }
59 :
60 272 : OUString ContextHandler::getFragmentPathFromRelation( const Relation& rRelation ) const
61 : {
62 272 : return mxBaseData->mxRelations->getFragmentPathFromRelation( rRelation );
63 : }
64 :
65 2094 : OUString ContextHandler::getFragmentPathFromRelId( const OUString& rRelId ) const
66 : {
67 2094 : return mxBaseData->mxRelations->getFragmentPathFromRelId( rRelId );
68 : }
69 :
70 256 : OUString ContextHandler::getFragmentPathFromFirstType( const OUString& rType ) const
71 : {
72 256 : return mxBaseData->mxRelations->getFragmentPathFromFirstType( rType );
73 : }
74 :
75 6894 : OUString ContextHandler::getFragmentPathFromFirstTypeFromOfficeDoc( const OUString& rType ) const
76 : {
77 6894 : return mxBaseData->mxRelations->getFragmentPathFromFirstTypeFromOfficeDoc( rType );
78 : }
79 :
80 5348 : void ContextHandler::implSetLocator( const Reference< XLocator >& rxLocator )
81 : {
82 5348 : mxBaseData->mxLocator = rxLocator;
83 5348 : }
84 :
85 : // com.sun.star.xml.sax.XFastContextHandler interface -------------------------
86 :
87 0 : void ContextHandler::startFastElement( sal_Int32, const Reference< XFastAttributeList >& ) throw( SAXException, RuntimeException, std::exception )
88 : {
89 0 : }
90 :
91 0 : void ContextHandler::startUnknownElement( const OUString&, const OUString&, const Reference< XFastAttributeList >& ) throw( SAXException, RuntimeException, std::exception )
92 : {
93 0 : }
94 :
95 0 : void ContextHandler::endFastElement( sal_Int32 ) throw( SAXException, RuntimeException, std::exception )
96 : {
97 0 : }
98 :
99 0 : void ContextHandler::endUnknownElement( const OUString&, const OUString& ) throw( SAXException, RuntimeException, std::exception )
100 : {
101 0 : }
102 :
103 0 : Reference< XFastContextHandler > ContextHandler::createFastChildContext( sal_Int32, const Reference< XFastAttributeList >& ) throw( SAXException, RuntimeException, std::exception )
104 : {
105 0 : return 0;
106 : }
107 :
108 384 : Reference< XFastContextHandler > ContextHandler::createUnknownChildContext( const OUString&, const OUString&, const Reference< XFastAttributeList >& ) throw( SAXException, RuntimeException, std::exception )
109 : {
110 384 : return 0;
111 : }
112 :
113 0 : void ContextHandler::characters( const OUString& ) throw( SAXException, RuntimeException, std::exception )
114 : {
115 0 : }
116 :
117 0 : void ContextHandler::ignorableWhitespace( const OUString& ) throw( SAXException, RuntimeException )
118 : {
119 0 : }
120 :
121 0 : void ContextHandler::processingInstruction( const OUString&, const OUString& ) throw( SAXException, RuntimeException )
122 : {
123 0 : }
124 :
125 : // record context interface ---------------------------------------------------
126 :
127 0 : ContextHandlerRef ContextHandler::createRecordContext( sal_Int32, SequenceInputStream& )
128 : {
129 0 : return 0;
130 : }
131 :
132 0 : void ContextHandler::startRecord( sal_Int32, SequenceInputStream& )
133 : {
134 0 : }
135 :
136 0 : void ContextHandler::endRecord( sal_Int32 )
137 : {
138 0 : }
139 :
140 : } // namespace core
141 : } // namespace oox
142 :
143 : /* vim:set shiftwidth=4 softtabstop=4 expandtab: */
|