2010-10-14 08:30:07 +02:00
|
|
|
/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
|
2012-06-12 18:11:58 +01:00
|
|
|
/*
|
|
|
|
* This file is part of the LibreOffice project.
|
|
|
|
*
|
|
|
|
* This Source Code Form is subject to the terms of the Mozilla Public
|
|
|
|
* License, v. 2.0. If a copy of the MPL was not distributed with this
|
|
|
|
* file, You can obtain one at http://mozilla.org/MPL/2.0/.
|
|
|
|
*
|
|
|
|
* This file incorporates work covered by the following license notice:
|
|
|
|
*
|
|
|
|
* Licensed to the Apache Software Foundation (ASF) under one or more
|
|
|
|
* contributor license agreements. See the NOTICE file distributed
|
|
|
|
* with this work for additional information regarding copyright
|
|
|
|
* ownership. The ASF licenses this file to you under the Apache
|
|
|
|
* License, Version 2.0 (the "License"); you may not use this file
|
|
|
|
* except in compliance with the License. You may obtain a copy of
|
|
|
|
* the License at http://www.apache.org/licenses/LICENSE-2.0 .
|
|
|
|
*/
|
2004-06-04 02:09:35 +00:00
|
|
|
|
2006-03-15 08:11:33 +00:00
|
|
|
#ifndef INCLUDED_CODEMAKER_UNOTYPE_HXX
|
|
|
|
#define INCLUDED_CODEMAKER_UNOTYPE_HXX
|
2004-06-04 02:09:35 +00:00
|
|
|
|
2013-11-09 14:11:23 -06:00
|
|
|
#include <sal/types.h>
|
2004-06-04 02:09:35 +00:00
|
|
|
|
|
|
|
#include <vector>
|
|
|
|
|
[API CHANGE] WIP: Experimental new binary type.rdb format
Make cppumaker work on top of unoidl/ instead of registry/, as a first step to
change all the various codemakers.
* API CHANGE: cppumaker no longer supports the -B switch, as that is meaningless
with the new format. When reading from an old-format .rdb file, /UCR is
hard-coded as the prefix now.
* TODO: The new format does not yet support deprecation annotations, so the
generated .hdl/.hpp files lack any SAL_DEPRECATED_INTERNALs for now.
* codemaker/typemanager.hxx is extended with access to unoidl/ functionality, so
the various codemakers can use registry/ and unoidl/ in parallel for now.
The access to registry/ functionality will be removed. (Added small throwaway
helper functions u2b/b2u to easily map between OString and OUString at the
remaining seams for now.)
* Includes a selective revert of ba044b1e9613ed30906a9a540b7da8392923e4e3
"remove needless forward rtl::OUString declarations" in those parts of
codemaker, unodevtools, unoidl that were covered by this local
work-in-progress patch; I would otherwise have hard a hard time re-applying
it.
* The generated .hdl/.hpp files are mostly unchanged, except for a few minor
things:
** Any SAL_DEPRECATED_INTERNALs are missing (see above).
** In comprehensive getCppuType definitions, some members were erroneously
classified as TypeCalss_UNKNOWN.
** In comprehensive getCppuType definitions, some unnecessary calls like
::cppu::UnoType< ::sal_Int32 >::get();
can be removed.
** For typedef sequence<X>, the .hdl file need not include X.hdl, but only needs
to forward-declare it.
** Unnecessary includes for optional bases of interfaces can be removed.
** Some numbering of local variable names (sMethodName1, ...) has changed.
Change-Id: Icad98f248ac15177337f1b4ab709a755a8af6238
2013-04-08 08:45:37 +02:00
|
|
|
namespace rtl { class OString; }
|
|
|
|
|
2004-06-04 02:09:35 +00:00
|
|
|
namespace codemaker {
|
|
|
|
|
|
|
|
namespace UnoType {
|
|
|
|
/**
|
[API CHANGE] WIP: Experimental new binary type.rdb format
Make cppumaker work on top of unoidl/ instead of registry/, as a first step to
change all the various codemakers.
* API CHANGE: cppumaker no longer supports the -B switch, as that is meaningless
with the new format. When reading from an old-format .rdb file, /UCR is
hard-coded as the prefix now.
* TODO: The new format does not yet support deprecation annotations, so the
generated .hdl/.hpp files lack any SAL_DEPRECATED_INTERNALs for now.
* codemaker/typemanager.hxx is extended with access to unoidl/ functionality, so
the various codemakers can use registry/ and unoidl/ in parallel for now.
The access to registry/ functionality will be removed. (Added small throwaway
helper functions u2b/b2u to easily map between OString and OUString at the
remaining seams for now.)
* Includes a selective revert of ba044b1e9613ed30906a9a540b7da8392923e4e3
"remove needless forward rtl::OUString declarations" in those parts of
codemaker, unodevtools, unoidl that were covered by this local
work-in-progress patch; I would otherwise have hard a hard time re-applying
it.
* The generated .hdl/.hpp files are mostly unchanged, except for a few minor
things:
** Any SAL_DEPRECATED_INTERNALs are missing (see above).
** In comprehensive getCppuType definitions, some members were erroneously
classified as TypeCalss_UNKNOWN.
** In comprehensive getCppuType definitions, some unnecessary calls like
::cppu::UnoType< ::sal_Int32 >::get();
can be removed.
** For typedef sequence<X>, the .hdl file need not include X.hdl, but only needs
to forward-declare it.
** Unnecessary includes for optional bases of interfaces can be removed.
** Some numbering of local variable names (sMethodName1, ...) has changed.
Change-Id: Icad98f248ac15177337f1b4ab709a755a8af6238
2013-04-08 08:45:37 +02:00
|
|
|
An enumeration of all the sorts of relevant UNOIDL entities.
|
2004-06-04 02:09:35 +00:00
|
|
|
*/
|
2016-02-23 12:01:14 +02:00
|
|
|
enum class Sort {
|
|
|
|
Void,
|
|
|
|
Boolean,
|
|
|
|
Byte,
|
|
|
|
Short,
|
|
|
|
UnsignedShort,
|
|
|
|
Long,
|
|
|
|
UnsignedLong,
|
|
|
|
Hyper,
|
|
|
|
UnsignedHyper,
|
|
|
|
Float,
|
|
|
|
Double,
|
|
|
|
Char,
|
|
|
|
String,
|
|
|
|
Type,
|
|
|
|
Any,
|
|
|
|
Sequence,
|
|
|
|
Module,
|
|
|
|
Enum,
|
|
|
|
PlainStruct,
|
|
|
|
PolymorphicStructTemplate,
|
|
|
|
InstantiatedPolymorphicStruct,
|
|
|
|
Exception,
|
|
|
|
Interface,
|
|
|
|
Typedef,
|
|
|
|
ConstantGroup,
|
|
|
|
SingleInterfaceBasedService,
|
|
|
|
AccumulationBasedService,
|
|
|
|
InterfaceBasedSingleton,
|
|
|
|
ServiceBasedSingleton
|
2004-06-04 02:09:35 +00:00
|
|
|
};
|
|
|
|
|
2013-04-16 17:37:01 +02:00
|
|
|
/**
|
2004-06-04 02:09:35 +00:00
|
|
|
Decomposes a UNO type name or UNO type registry name.
|
|
|
|
|
|
|
|
@param type a binary UNO type name or UNO type registry name
|
|
|
|
|
|
|
|
@param rank if non-null, returns the rank of the denoted UNO type (which
|
|
|
|
is zero for any given type that does not denote a UNO sequence type)
|
|
|
|
|
|
|
|
@param arguments if non-null, the type arguments are stripped from an
|
|
|
|
instantiated polymorphic struct type and returned via this parameter (in
|
|
|
|
the correct order); if null, type arguments are not stripped from
|
|
|
|
instantiated polymorphic struct types
|
|
|
|
|
|
|
|
@return the base part of the given type
|
|
|
|
*/
|
[API CHANGE] WIP: Experimental new binary type.rdb format
Make cppumaker work on top of unoidl/ instead of registry/, as a first step to
change all the various codemakers.
* API CHANGE: cppumaker no longer supports the -B switch, as that is meaningless
with the new format. When reading from an old-format .rdb file, /UCR is
hard-coded as the prefix now.
* TODO: The new format does not yet support deprecation annotations, so the
generated .hdl/.hpp files lack any SAL_DEPRECATED_INTERNALs for now.
* codemaker/typemanager.hxx is extended with access to unoidl/ functionality, so
the various codemakers can use registry/ and unoidl/ in parallel for now.
The access to registry/ functionality will be removed. (Added small throwaway
helper functions u2b/b2u to easily map between OString and OUString at the
remaining seams for now.)
* Includes a selective revert of ba044b1e9613ed30906a9a540b7da8392923e4e3
"remove needless forward rtl::OUString declarations" in those parts of
codemaker, unodevtools, unoidl that were covered by this local
work-in-progress patch; I would otherwise have hard a hard time re-applying
it.
* The generated .hdl/.hpp files are mostly unchanged, except for a few minor
things:
** Any SAL_DEPRECATED_INTERNALs are missing (see above).
** In comprehensive getCppuType definitions, some members were erroneously
classified as TypeCalss_UNKNOWN.
** In comprehensive getCppuType definitions, some unnecessary calls like
::cppu::UnoType< ::sal_Int32 >::get();
can be removed.
** For typedef sequence<X>, the .hdl file need not include X.hdl, but only needs
to forward-declare it.
** Unnecessary includes for optional bases of interfaces can be removed.
** Some numbering of local variable names (sMethodName1, ...) has changed.
Change-Id: Icad98f248ac15177337f1b4ab709a755a8af6238
2013-04-08 08:45:37 +02:00
|
|
|
rtl::OString decompose(
|
2015-11-10 10:11:36 +01:00
|
|
|
rtl::OString const & type, sal_Int32 * rank = nullptr,
|
|
|
|
std::vector< rtl::OString > * arguments = nullptr);
|
2004-06-04 02:09:35 +00:00
|
|
|
}
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
#endif
|
2010-10-14 08:30:07 +02:00
|
|
|
|
|
|
|
/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
|