Teach symstore more duplicated DLLs
[LibreOffice.git] / idl / inc / types.hxx
bloba0f796fc66f97d8d7fd8dac97ff755572878e57d
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/.
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_IDL_INC_TYPES_HXX
21 #define INCLUDED_IDL_INC_TYPES_HXX
23 #include <rtl/strbuf.hxx>
24 #include <tools/solar.h>
25 #include <tools/ref.hxx>
26 #include "basobj.hxx"
28 class SvMetaType;
29 class SvMetaSlot;
30 typedef SvRefMemberList< SvMetaSlot* > SvSlotElementList;
32 class SvMetaAttribute : public SvMetaReference
34 public:
35 tools::SvRef<SvMetaType> aType;
36 SvIdentifier aSlotId;
37 SvMetaAttribute();
38 SvMetaAttribute( SvMetaType * );
40 void SetSlotId( const SvIdentifier & rId )
41 { aSlotId = rId; }
42 const SvIdentifier& GetSlotId() const;
43 SvMetaType * GetType() const;
45 virtual bool Test( SvTokenStream & rInStm );
46 virtual bool ReadSvIdl( SvIdlDataBase &, SvTokenStream & rInStm ) override;
47 sal_uLong MakeSfx( OStringBuffer& rAtrrArray ) const;
48 virtual void Insert( SvSlotElementList& );
51 enum MetaTypeType { Method, Struct, Base, Enum, Interface, Shell };
53 class SvMetaType : public SvMetaReference
55 SvRefMemberList<SvMetaAttribute *> aAttrList;
56 MetaTypeType nType;
57 bool bIsItem;
59 void WriteSfxItem( const OString& rItemName, SvIdlDataBase const & rBase,
60 SvStream & rOutStm );
61 protected:
62 bool ReadHeaderSvIdl( SvTokenStream & rInStm );
63 public:
64 SvMetaType();
65 SvMetaType( const OString& rTypeName );
67 virtual ~SvMetaType() override;
69 virtual void ReadContextSvIdl( SvIdlDataBase &, SvTokenStream & rInStm ) override;
71 SvRefMemberList<SvMetaAttribute *>&
72 GetAttrList() { return aAttrList; }
73 sal_uLong GetAttrCount() const { return aAttrList.size(); }
75 void SetType( MetaTypeType nT );
76 MetaTypeType GetMetaTypeType() const { return nType; }
77 SvMetaType * GetBaseType() const;
78 SvMetaType * GetReturnType() const;
79 void SetItem(bool b) { bIsItem = b; }
80 bool IsItem() const { return bIsItem; }
82 virtual bool ReadSvIdl( SvIdlDataBase &, SvTokenStream & rInStm ) override;
84 sal_uLong MakeSfx( OStringBuffer& rAtrrArray );
85 virtual void WriteSfx( SvIdlDataBase & rBase, SvStream & rOutStm );
86 bool ReadMethodArgs( SvIdlDataBase & rBase,
87 SvTokenStream & rInStm );
90 class SvMetaTypeString : public SvMetaType
92 public:
93 SvMetaTypeString();
96 class SvMetaEnumValue : public SvMetaObject
98 public:
99 SvMetaEnumValue();
102 class SvMetaTypeEnum : public SvMetaType
104 public:
105 SvRefMemberList<SvMetaEnumValue *> aEnumValueList;
106 OString aPrefix;
107 SvMetaTypeEnum();
110 class SvMetaTypevoid : public SvMetaType
112 public:
113 SvMetaTypevoid();
117 #endif // INCLUDED_IDL_INC_TYPES_HXX
119 /* vim:set shiftwidth=4 softtabstop=4 expandtab: */