bump product version to 4.1.6.2
[LibreOffice.git] / writerfilter / source / rtftok / rtfvalue.hxx
blob02bf93167b8a171e998a9eeb6c31ef0a86b2e437
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/.
8 */
10 #ifndef _RTFVALUE_HXX_
11 #define _RTFVALUE_HXX_
13 #include <resourcemodel/WW8ResourceModel.hxx>
14 #include <com/sun/star/io/XInputStream.hpp>
15 #include <com/sun/star/embed/XEmbeddedObject.hpp>
17 namespace writerfilter {
18 namespace rtftok {
19 class RTFSprms;
20 /// Value of an RTF keyword
21 class RTFValue
22 : public Value
24 public:
25 typedef boost::shared_ptr<RTFValue> Pointer_t;
26 RTFValue(int nValue, OUString sValue, RTFSprms rAttributes, RTFSprms rSprms, uno::Reference<drawing::XShape> rShape,
27 uno::Reference<io::XInputStream> rStream, uno::Reference<embed::XEmbeddedObject> rObject, bool bForceString);
28 RTFValue(int nValue);
29 RTFValue(OUString sValue, bool bForce = false);
30 RTFValue(RTFSprms rAttributes);
31 RTFValue(RTFSprms rAttributes, RTFSprms rSprms);
32 RTFValue(uno::Reference<drawing::XShape> rShape);
33 RTFValue(uno::Reference<io::XInputStream> rStream);
34 RTFValue(uno::Reference<embed::XEmbeddedObject> rObject);
35 virtual ~RTFValue();
36 void setString(OUString sValue);
37 virtual int getInt() const;
38 virtual OUString getString() const;
39 virtual uno::Any getAny() const;
40 virtual writerfilter::Reference<Properties>::Pointer_t getProperties();
41 virtual writerfilter::Reference<Stream>::Pointer_t getStream();
42 virtual writerfilter::Reference<BinaryObj>::Pointer_t getBinary();
43 virtual std::string toString() const;
44 virtual RTFValue* Clone();
45 RTFSprms& getAttributes();
46 RTFSprms& getSprms();
47 bool equals(RTFValue& rOther);
48 private:
49 RTFValue& operator=(RTFValue const& rOther);
50 int m_nValue;
51 OUString m_sValue;
52 boost::shared_ptr<RTFSprms> m_pAttributes;
53 boost::shared_ptr<RTFSprms> m_pSprms;
54 uno::Reference<drawing::XShape> m_xShape;
55 uno::Reference<io::XInputStream> m_xStream;
56 uno::Reference<embed::XEmbeddedObject> m_xObject;
57 bool m_bForceString;
59 } // namespace rtftok
60 } // namespace writerfilter
62 #endif // _RTFVALUE_HXX_
64 /* vim:set shiftwidth=4 softtabstop=4 expandtab: */