summaryrefslogtreecommitdiff
path: root/bridges/inc
diff options
context:
space:
mode:
authorThomas Arnhold <thomas@arnhold.org>2012-06-26 17:51:23 +0200
committerThomas Arnhold <thomas@arnhold.org>2012-06-27 13:34:23 +0200
commit6fcac7dfc4f2ad85e08aea781cfab28443e3781e (patch)
treefbbf82cb46dde6f13b6f5f11664c2c908b5709e1 /bridges/inc
parente5c28b86bed03c70bbe3054ccfcc6cb96291c580 (diff)
Remove unused include files
Those never get included at any point in the code. Change-Id: I17736e005635b9e57759cfc95176a99e7c5e8988
Diffstat (limited to 'bridges/inc')
-rw-r--r--bridges/inc/bridges/cpp_uno/type_misc.hxx123
1 files changed, 0 insertions, 123 deletions
diff --git a/bridges/inc/bridges/cpp_uno/type_misc.hxx b/bridges/inc/bridges/cpp_uno/type_misc.hxx
deleted file mode 100644
index d2353d06eba5..000000000000
--- a/bridges/inc/bridges/cpp_uno/type_misc.hxx
+++ /dev/null
@@ -1,123 +0,0 @@
-/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
-/*
- * 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 .
- */
-#ifndef _BRIDGES_CPP_UNO_TYPE_MISC_HXX_
-#define _BRIDGES_CPP_UNO_TYPE_MISC_HXX_
-
-#include <sal/types.h>
-#include <typelib/typedescription.h>
-
-
-/** Determines whether given type might relate or relates to an interface,
- i.e. values of this type are interface or may contain interface(s).<br>
- @param pTypeDescr type description of type
- @return true if type might relate to an interface, false otherwise
-*/
-inline bool cppu_relatesToInterface( typelib_TypeDescription * pTypeDescr ) SAL_THROW(())
-{
- switch (pTypeDescr->eTypeClass)
- {
-// case typelib_TypeClass_TYPEDEF:
- case typelib_TypeClass_SEQUENCE:
- {
- switch (((typelib_IndirectTypeDescription *)pTypeDescr)->pType->eTypeClass)
- {
- case typelib_TypeClass_INTERFACE:
- case typelib_TypeClass_UNION: // might relate to interface
- case typelib_TypeClass_ANY: // might relate to interface
- return true;
- case typelib_TypeClass_SEQUENCE:
- case typelib_TypeClass_STRUCT:
- case typelib_TypeClass_EXCEPTION:
- {
- typelib_TypeDescription * pTD = 0;
- TYPELIB_DANGER_GET( &pTD, ((typelib_IndirectTypeDescription *)pTypeDescr)->pType );
- bool bRel = cppu_relatesToInterface( pTD );
- TYPELIB_DANGER_RELEASE( pTD );
- return bRel;
- }
- default:
- return false;
- }
- }
- case typelib_TypeClass_STRUCT:
- case typelib_TypeClass_EXCEPTION:
- {
- // ...optimized... to avoid getDescription() calls!
- typelib_CompoundTypeDescription * pComp = (typelib_CompoundTypeDescription *)pTypeDescr;
- typelib_TypeDescriptionReference ** pTypes = pComp->ppTypeRefs;
- for ( sal_Int32 nPos = pComp->nMembers; nPos--; )
- {
- switch (pTypes[nPos]->eTypeClass)
- {
- case typelib_TypeClass_INTERFACE:
- case typelib_TypeClass_UNION: // might relate to interface
- case typelib_TypeClass_ANY: // might relate to interface
- return true;
-// case typelib_TypeClass_TYPEDEF:
- case typelib_TypeClass_SEQUENCE:
- case typelib_TypeClass_STRUCT:
- case typelib_TypeClass_EXCEPTION:
- {
- typelib_TypeDescription * pTD = 0;
- TYPELIB_DANGER_GET( &pTD, pTypes[nPos] );
- bool bRel = cppu_relatesToInterface( pTD );
- TYPELIB_DANGER_RELEASE( pTD );
- if (bRel)
- return true;
- }
- default:
- break;
- }
- }
- if (pComp->pBaseTypeDescription)
- return cppu_relatesToInterface( (typelib_TypeDescription *)pComp->pBaseTypeDescription );
- return false;
- }
- case typelib_TypeClass_UNION: // might relate to interface
- case typelib_TypeClass_ANY: // might relate to interface
- case typelib_TypeClass_INTERFACE:
- return true;
- default:
- return false;
- }
-}
-
-/** Determines whether given type is a cpp simple type, e.g. int, enum.<br>
- @param eTypeClass type class of type
- @return true if type is a cpp simple type, false otherwise
-*/
-inline bool cppu_isSimpleType( typelib_TypeClass eTypeClass ) SAL_THROW(())
-{
- return (eTypeClass <= typelib_TypeClass_ENUM &&
- eTypeClass != typelib_TypeClass_STRING &&
- eTypeClass != typelib_TypeClass_ANY &&
- eTypeClass != typelib_TypeClass_TYPE);
-}
-/** Determines whether given type is a cpp simple type, e.g. int, enum.<br>
- @param pTypeDescr type description of type
- @return true if type is a cpp simple type, false otherwise
-*/
-inline bool cppu_isSimpleType( typelib_TypeDescription * pTypeDescr ) SAL_THROW(())
-{
- return cppu_isSimpleType( pTypeDescr->eTypeClass );
-}
-
-#endif
-
-/* vim:set shiftwidth=4 softtabstop=4 expandtab: */