1 /* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4; fill-column: 100 -*- */
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/.
12 #include <unordered_set>
13 #include <string_view>
15 #include <codemaker/typemanager.hxx>
16 #include <rtl/string.hxx>
17 #include <unoidl/unoidl.hxx>
19 #include "netoptions.hxx"
25 : m_manager(new TypeManager())
32 void initProducer(const NetOptions
& options
);
36 void produceType(const OString
& name
);
37 void produceModule(std::string_view name
, const rtl::Reference
<unoidl::MapCursor
>& cursor
);
38 void produceEnum(std::string_view name
, const rtl::Reference
<unoidl::EnumTypeEntity
>& entity
);
39 void producePlainStruct(std::string_view name
,
40 const rtl::Reference
<unoidl::PlainStructTypeEntity
>& entity
);
42 producePolyStruct(std::string_view name
,
43 const rtl::Reference
<unoidl::PolymorphicStructTypeTemplateEntity
>& entity
);
44 void produceException(std::string_view name
,
45 const rtl::Reference
<unoidl::ExceptionTypeEntity
>& entity
);
46 void produceInterface(std::string_view name
,
47 const rtl::Reference
<unoidl::InterfaceTypeEntity
>& entity
);
48 void produceTypedef(std::string_view name
, const rtl::Reference
<unoidl::TypedefEntity
>& entity
);
49 void produceConstantGroup(std::string_view name
,
50 const rtl::Reference
<unoidl::ConstantGroupEntity
>& entity
);
51 void produceService(std::string_view name
,
52 const rtl::Reference
<unoidl::SingleInterfaceBasedServiceEntity
>& entity
);
53 void produceSingleton(std::string_view name
,
54 const rtl::Reference
<unoidl::InterfaceBasedSingletonEntity
>& entity
);
56 OString
getNetName(std::string_view name
);
57 OString
getNetName(std::u16string_view name
);
60 rtl::Reference
<TypeManager
> m_manager
;
62 std::unordered_set
<OString
> m_startingTypes
;
63 std::unordered_set
<OString
> m_typesProduced
;
64 std::unordered_map
<OString
, OString
> m_typedefs
;
71 /* vim:set shiftwidth=4 softtabstop=4 expandtab cinoptions=b1,g0,N-s cinkeys+=0=break: */