diff options
Diffstat (limited to 'autodoc/source/ary')
67 files changed, 0 insertions, 9654 deletions
diff --git a/autodoc/source/ary/doc/d_docu.cxx b/autodoc/source/ary/doc/d_docu.cxx deleted file mode 100644 index 3d5170545047..000000000000 --- a/autodoc/source/ary/doc/d_docu.cxx +++ /dev/null @@ -1,53 +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 . - */ - -#include <precomp.h> -#include <ary/doc/d_docu.hxx> - - -// NOT FULLY DEFINED SERVICES -#include <ary/doc/d_node.hxx> - -namespace ary -{ -namespace doc -{ - -Documentation::Documentation() - : pData(0) -{ -} - -Documentation::~Documentation() -{ -} - -void -Documentation::do_Accept(csv::ProcessorIfc & io_processor) const -{ - csv::CheckedCall(io_processor,*this); -} - - - - -} // namespace doc -} // namespace ary - -/* vim:set shiftwidth=4 softtabstop=4 expandtab: */ diff --git a/autodoc/source/ary/doc/d_node.cxx b/autodoc/source/ary/doc/d_node.cxx deleted file mode 100644 index 1d160c0c84f6..000000000000 --- a/autodoc/source/ary/doc/d_node.cxx +++ /dev/null @@ -1,63 +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 . - */ - -#include <precomp.h> -#include <ary/doc/d_node.hxx> - - -namespace ary -{ -namespace doc -{ - - - -Node::~Node() -{ -} - -Node::Node(nodetype::id i_type) - : nType(i_type), - pNext(0) -{ -} - -void -Node::Add_toChain( DYN Node & pass_nextNode ) -{ - if (NOT pNext) - pNext = &pass_nextNode; - else - pNext->Add_toChain(pass_nextNode); -} - -uintt -Node::ListSize() const -{ - return pNext - ? pNext->ListSize() + 1 - : 1; -} - - - -} // namespace doc -} // namespace ary - -/* vim:set shiftwidth=4 softtabstop=4 expandtab: */ diff --git a/autodoc/source/ary/doc/d_oldidldocu.cxx b/autodoc/source/ary/doc/d_oldidldocu.cxx deleted file mode 100644 index 90e28f7c264f..000000000000 --- a/autodoc/source/ary/doc/d_oldidldocu.cxx +++ /dev/null @@ -1,70 +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 . - */ - -#include <precomp.h> -#include <ary/doc/d_oldidldocu.hxx> - -// NOT FULLY DEFINED SERVICES -#include <docu_node_ids.hxx> - - - -namespace ary -{ -namespace doc -{ - -using namespace ::ary::inf; - - -OldIdlDocu::OldIdlDocu() - : Node(docnt::nt_OldIdlDocu), - aShort(), - aDescription(), - aDeprecatedText(), - aTags(), - pExternShort(0), - bIsPublished(false), - bIsDeprecated(false), - bIsOptional(false) -{ -} - -OldIdlDocu::~OldIdlDocu() -{ -} - -void -OldIdlDocu::AddToken2DeprecatedText( DYN DocuToken & let_drToken ) -{ - aDeprecatedText.AddToken(let_drToken); -} - -void -OldIdlDocu::do_Accept(csv::ProcessorIfc & io_processor) const -{ - csv::CheckedCall(io_processor, *this); -} - - - -} // namespace info -} // namespace ary - -/* vim:set shiftwidth=4 softtabstop=4 expandtab: */ diff --git a/autodoc/source/ary/idl/i2s_calculator.cxx b/autodoc/source/ary/idl/i2s_calculator.cxx deleted file mode 100644 index b4e369c84ff2..000000000000 --- a/autodoc/source/ary/idl/i2s_calculator.cxx +++ /dev/null @@ -1,965 +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 . - */ - -#include <precomp.h> -#include "i2s_calculator.hxx" - -// NOT FULLY DEFINED SERVICES -#include <algorithm> -#include <string.h> -#include <cosv/file.hxx> -#include <ary/qualiname.hxx> -#include <ary/idl/i_enum.hxx> -#include <ary/idl/i_exception.hxx> -#include <ary/idl/i_function.hxx> -#include <ary/idl/i_gate.hxx> -#include <ary/idl/i_interface.hxx> -#include <ary/idl/ik_interface.hxx> -#include <ary/idl/i_module.hxx> -#include <ary/idl/i_property.hxx> -#include <ary/idl/i_service.hxx> -#include <ary/idl/i_singleton.hxx> -#include <ary/idl/i_siservice.hxx> -#include <ary/idl/i_sisingleton.hxx> -#include <ary/idl/i_struct.hxx> -#include <ary/idl/i_structelem.hxx> -#include <ary/idl/i_typedef.hxx> -#include <ary/idl/ip_ce.hxx> -#include <ary/idl/ip_type.hxx> -#include <ary/namesort.hxx> -#include <nametreenode.hxx> -#include "i_nnfinder.hxx" -#include "ia_ce.hxx" -#include "ia_type.hxx" -#include "is_ce.hxx" -#include "is_type.hxx" -#include "it_ce.hxx" -#include "it_explicit.hxx" -#include "it_sequence.hxx" -#include "it_xnameroom.hxx" - - -namespace ary -{ -namespace idl -{ - -template <class DEST> -DEST * -SecondariesCalculator::SearchCe4Type(Type_id i_type) -{ - Ce_id - ce = lhf_Search_CeFromTypeId(i_type); - if (ce.IsValid()) - return ary_cast<DEST>(& my_CeStorage()[ce]); - return 0; -} - - -typedef stg::const_iterator<CodeEntity> stg_citerator; -typedef stg::iterator<CodeEntity> stg_iterator; - -typedef stg::filter_iterator<CodeEntity,Interface> - interface_iterator; - -typedef stg::filter_iterator<Type,ExplicitType> - explicittype_iterator; - -typedef ary::stg::const_filter_iterator<CodeEntity,Typedef> - typedef_citerator; - - -inline Service * -SecondariesCalculator::lhf_SearchService( Type_id i_nType ) -{ - return SearchCe4Type<Service>(i_nType); -} - -inline Interface * -SecondariesCalculator::lhf_SearchInterface( Type_id i_nType ) -{ - return SearchCe4Type<Interface>(i_nType); -} - -inline Struct * -SecondariesCalculator::lhf_SearchStruct( Type_id i_nType ) -{ - return SearchCe4Type<Struct>(i_nType); -} - -inline Exception * -SecondariesCalculator::lhf_SearchException( Type_id i_nType ) -{ - return SearchCe4Type<Exception>(i_nType); -} - -inline const Ce_Storage & -SecondariesCalculator::my_CeStorage() const -{ - csv_assert(pCes != 0); - return pCes->Storage(); -} - -inline const Type_Storage & -SecondariesCalculator::my_TypeStorage() const -{ - csv_assert(pTypes != 0); - return pTypes->Storage(); -} - -inline Ce_Storage & -SecondariesCalculator::my_CeStorage() -{ - csv_assert(pCes != 0); - return pCes->Storage(); -} - -inline Type_Storage & -SecondariesCalculator::my_TypeStorage() -{ - csv_assert(pTypes != 0); - return pTypes->Storage(); -} - -inline void -SecondariesCalculator::insert_into2sList( CodeEntity & o_out, - int i_listIndex, - Ce_id i_nCe ) - { o_out.Secondaries().Access_List(i_listIndex).push_back(i_nCe); } - - -SecondariesCalculator::SecondariesCalculator( CeAdmin & i_ces, - TypeAdmin & i_types ) - : pCes(&i_ces), - pTypes(&i_types) -{ -} - -SecondariesCalculator::~SecondariesCalculator() -{ -} - - -void -SecondariesCalculator::CheckAllInterfaceBases() -{ - Module & - rGlobalNamespace = pCes->GlobalNamespace(); - QualifiedName - aXInterface("::com::sun::star::uno::XInterface","::"); - - const Type & - rType = pTypes->CheckIn_Type( aXInterface, - 0, - rGlobalNamespace.CeId(), - 0 ); - Type_id - nTypeXInterface = rType.TypeId(); - const ExplicitType & - rExplType = ary_cast<ExplicitType>(rType); - Ce_id - nCeXInterface = lhf_Search_CeForType(rExplType); - - interface_iterator itEnd( my_CeStorage().End() ); - for ( interface_iterator it( my_CeStorage().BeginUnreserved() ); - it != itEnd; - ++it ) - { - if (NOT it.IsValid()) - continue; - - Interface & - rInterface = *it; - if ( NOT rInterface.HasBase() // According to UNO IDL syntax, an interface without base has com::sun::star::uno::XInterface as base. - AND rInterface.CeId() != nCeXInterface ) // XInterface must not be base of itself. - { - rInterface.Add_Base(nTypeXInterface, 0); - } - } // end for -} - -void -SecondariesCalculator::Connect_Types2Ces() -{ - explicittype_iterator itEnd( my_TypeStorage().End() ); - for ( explicittype_iterator it( my_TypeStorage().BeginUnreserved() ); - it != itEnd; - ++it ) - { - if (NOT it.IsValid()) - continue; - - ExplicitType & - rType = ary_cast<ExplicitType>(*it); - Ce_id - nRelatedCe = lhf_Search_CeForType(rType); - if (nRelatedCe.IsValid()) - { - Ce_Type * - pNew = new Ce_Type(nRelatedCe, rType.TemplateParameters()); - my_TypeStorage().Replace_Entity( rType.TypeId(), - *pNew ); - } - } // end for -} - -void -SecondariesCalculator::Gather_CrossReferences() -{ - gather_Synonyms(); - - for ( stg_iterator it = my_CeStorage().Begin(); - it != my_CeStorage().End(); - ++it ) - { - (*it).Accept( static_cast< SPInst_asHost& >(*this) ); - - } // end for - - sort_All2s(); -} - -void -SecondariesCalculator::Make_Links2DeveloperManual( - const String & i_devman_reffilepath ) -{ - csv::File - aFile(i_devman_reffilepath, csv::CFM_READ); - csv::OpenCloseGuard - aFileOpener(aFile); - if (aFileOpener) - { - Read_Links2DevManual(aFile); - } -} - -namespace -{ - -enum E_LinkMode -{ - link2descr, - link2ref -}; - -struct OrderCeIdsByName -{ - OrderCeIdsByName( - const Ce_Storage & i_storage ) - : rStorage(i_storage), - aNameComparison() {} - bool operator()( - Ce_id i_ce1, - Ce_id i_ce2 ) const - { - return aNameComparison( rStorage[i_ce1].LocalName(), - rStorage[i_ce2].LocalName() ); - } - - private: - const Ce_Storage & rStorage; - LesserName aNameComparison; -}; - - -} - - - -void -SecondariesCalculator::do_Process( const Service & i_rData ) -{ - const Service & - rService = ary_cast<Service>(i_rData); - - // Interfaces: - assignImplementation_toAServicesInterfaces( rService.CeId(), - rService.CeId(), - interface_2s_ExportingServices ); - // Services and their interfaces: - recursive_AssignIncludingService(rService.CeId(), rService); -} - -void -SecondariesCalculator::do_Process( const Interface & i_rData ) -{ - assign_AsDerivedInterface( ary_cast<Interface>(i_rData) ); -} - -void -SecondariesCalculator::do_Process( const Struct & i_rData ) -{ - assign_AsDerivedStruct( ary_cast<Struct>(i_rData) ); -} - -void -SecondariesCalculator::do_Process( const Exception & i_rData ) -{ - assign_AsDerivedException( ary_cast<Exception>(i_rData) ); -} - -void -SecondariesCalculator::do_Process( const Typedef & ) -{ - // KORR_FUTURE - // Find out what was meant here ??? - -// const Typedef & -// rTypedef = ary_cast<Typedef>(i_rData); -} - -void -SecondariesCalculator::do_Process( const Singleton & i_rData ) -{ - const Singleton & - rSingleton = ary_cast<Singleton>(i_rData); - - Service * - pServ = lhf_SearchService(rSingleton.AssociatedService()); - if (pServ != 0) - { - insert_into2sUnique( *pServ, - service_2s_InstantiatingSingletons, - rSingleton.CeId() ); - } - - // Interfaces: - assignImplementation_toAServicesInterfaces( rSingleton.CeId(), - lhf_Search_CeFromTypeId(rSingleton.AssociatedService()), - interface_2s_ExportingSingletons ); -} - -void -SecondariesCalculator::do_Process( const SglIfcService & i_rData ) -{ - const SglIfcService & - rSglIfcService = ary_cast<SglIfcService>(i_rData); - - assignImplementation_toAServicesInterfaces( rSglIfcService.CeId(), - rSglIfcService.CeId(), - interface_2s_ExportingServices ); -} - -void -SecondariesCalculator::do_Process( const SglIfcSingleton & i_rData ) -{ - const SglIfcSingleton & - rSglIfcSingleton = ary_cast<SglIfcSingleton>(i_rData); - - Type_id nBase = rSglIfcSingleton.BaseInterface(); - recursive_AssignImplementation_toExportedInterface( rSglIfcSingleton.CeId(), - nBase, - interface_2s_ExportingSingletons ); -} - -void -SecondariesCalculator::do_Process( const Function & i_rData ) -{ - const Function & - rFunction = ary_cast<Function>(i_rData); - - recursive_AssignFunction_toCeAsReturn(rFunction.CeId(), rFunction.ReturnType()); - - for ( Function::ParamList::const_iterator itp = rFunction.Parameters().begin(); - itp != rFunction.Parameters().end(); - ++itp ) - { - recursive_AssignFunction_toCeAsParameter(rFunction.CeId(), (*itp).Type()); - } // end for (itp) - - for ( Function::ExceptionList::const_iterator itx = rFunction.Exceptions().begin(); - itx != rFunction.Exceptions().end(); - ++itx ) - { - Exception * - pX = lhf_SearchException(*itx); - if (pX != 0) - { - insert_into2sUnique(*pX, exception_2s_RaisingFunctions, rFunction.CeId()); - } - } // end for (itx) -} - -void -SecondariesCalculator::do_Process( const StructElement & i_rData ) -{ - const StructElement & - rStructElement = ary_cast<StructElement>(i_rData); - - recursive_AssignStructElement_toCeAsDataType(rStructElement.CeId(), rStructElement.Type()); -} - -void -SecondariesCalculator::do_Process( const Property & i_rData ) -{ - const Property & - rProperty = ary_cast<Property>(i_rData); - - recursive_AssignStructElement_toCeAsDataType(rProperty.CeId(), rProperty.Type()); -} - -Ce_id -SecondariesCalculator::lhf_Search_CeForType( const ExplicitType & i_rType ) const -{ - const ExplicitNameRoom & - rExplicitNameRoom = ary_cast<ExplicitNameRoom>( - my_TypeStorage()[i_rType.NameRoom()] ); - Find_ModuleNode - rNodeFinder( my_CeStorage(), - rExplicitNameRoom.NameChain_Begin(), - rExplicitNameRoom.NameChain_End(), - i_rType.Name() ); - - if ( rExplicitNameRoom.IsAbsolute() ) - { - const Module & - rGlobalNamespace = ary_cast<Module>( - my_CeStorage()[predefined::ce_GlobalNamespace]); - return Search_SubTree( rGlobalNamespace, - rNodeFinder ); - } - else - { - const Module & - rStartModule = ary_cast<Module>( - my_CeStorage()[i_rType.ModuleOfOccurrence()]); - Ce_id ret = Search_SubTree_UpTillRoot( rStartModule, - rNodeFinder ); - return ret; - } // endif (rExplicitNameRoom.IsAbsolute()) else -} - -Ce_id -SecondariesCalculator::lhf_Search_CeFromTypeId( Type_id i_nType ) const -{ - if (NOT i_nType.IsValid()) - return Ce_id(0); - const Ce_Type * - pType = ary_cast<Ce_Type>( & my_TypeStorage()[i_nType] ); - return pType != 0 - ? pType->RelatedCe() - : Ce_id_Null(); -} - -void -SecondariesCalculator::assign_CurLink( char * i_text, - const String & i_link, - const String & i_linkUI, - bool i_isDescr, - int i_lineCount ) -{ - csv_assert(i_text != 0); - - const ary::idl::Module * - pModule = & ary_cast<Module>( - my_CeStorage()[predefined::ce_GlobalNamespace]); - - char * pPastNext = 0; - char * pNext = i_text; - for ( ; - (pPastNext = strstr(pNext,".")) != 0; - pNext = pPastNext + 1 ) - { - String sNext(pNext, pPastNext-pNext); - Ce_id nModule = pModule->Search_Name(sNext); - if (nModule.IsValid()) - { - pModule = ary_cast<Module>( & my_CeStorage()[nModule] ); - } - else - { - pModule = 0; - } - - if (pModule == 0) - { - Cerr() << "Warning: Invalid line nr. " - << i_lineCount - << " in DevelopersGuide reference file:\n" - << reinterpret_cast< const char* >(i_text) - << "\n" - << Endl(); - return; - } - } // end for - - pPastNext = strchr(pNext,':'); - bool bMember = pPastNext != 0; - String sCe( pNext, (bMember ? csv::str::size(pPastNext-pNext) : csv::str::maxsize) ); - -// KORR_FUTURE -// String sMember(bMember ? pPastNext+1, ""); - - Ce_id nCe = pModule->Search_Name(sCe); - if (NOT nCe.IsValid()) - { - Cerr() << "Warning: Invalid line nr. " - << i_lineCount - << " in DevelopersGuide reference file:\n" - << reinterpret_cast< const char* >(i_text) - << "\n" - << Endl(); - return; - } - - CodeEntity & - rCe = my_CeStorage()[nCe]; - if (NOT bMember) - { - if (i_isDescr) - rCe.Secondaries().Add_Link2DescriptionInManual(i_link, i_linkUI); - else - rCe.Secondaries().Add_Link2RefInManual(i_link, i_linkUI); - return; - } - else - { - // KORR_FUTURE - // Provisorial just doing nothing (or may be - // adding a link at main Ces lists). -// if (i_isDescr) -// rCe.Secondaries().Add_Link2DescriptionInManual(i_link); -// else -// rCe.Secondaries().Add_Link2RefInManual(i_link); - } -} - -void -SecondariesCalculator::gather_Synonyms() -{ - const Ce_Storage & - cstrg = my_CeStorage(); - typedef_citerator itEnd(cstrg.End()); - for ( typedef_citerator it(cstrg.Begin()); - it != itEnd; - ++it ) - { - if (NOT it.IsValid()) - continue; - - const Typedef & - rTypedef = *it; - recursive_AssignAsSynonym(rTypedef.CeId(), rTypedef); - } // end for (itTd) -} - -void -SecondariesCalculator::recursive_AssignAsSynonym( Ce_id i_synonymousTypedefsId, - const Typedef & i_TypedefToCheck ) -{ - Ce_id - nCe = lhf_Search_CeFromTypeId(i_TypedefToCheck.DefiningType()); - if (NOT nCe.IsValid()) - return; - CodeEntity & - rCe = my_CeStorage()[nCe]; - - switch (rCe.AryClass()) // KORR_FUTURE: make this faster, remove switch. - { - case Interface::class_id: - insert_into2sList( rCe, - interface_2s_SynonymTypedefs, - i_synonymousTypedefsId ); - break; - case Struct::class_id: - insert_into2sList( rCe, - struct_2s_SynonymTypedefs, - i_synonymousTypedefsId ); - break; - case Enum::class_id: - insert_into2sList( rCe, - enum_2s_SynonymTypedefs, - i_synonymousTypedefsId ); - break; - case Typedef::class_id: - insert_into2sList( rCe, - typedef_2s_SynonymTypedefs, - i_synonymousTypedefsId ); - recursive_AssignAsSynonym( i_synonymousTypedefsId, - static_cast< Typedef& >(rCe) ); - break; - // default: do nothing. - } -} - -void -SecondariesCalculator::recursive_AssignIncludingService( Ce_id i_includingServicesId, - const Service & i_ServiceToCheckItsIncludes ) -{ - Dyn_StdConstIterator<CommentedRelation> - pIncludedServices; - i_ServiceToCheckItsIncludes.Get_IncludedServices(pIncludedServices); - - for ( StdConstIterator<CommentedRelation> & - itServ = *pIncludedServices; - itServ; - ++itServ ) - { - Service * - pServ = lhf_SearchService((*itServ).Type()); - if (pServ != 0) - { - insert_into2sUnique( *pServ, - service_2s_IncludingServices, - i_includingServicesId - ); - recursive_AssignIncludingService(i_includingServicesId, *pServ); - - } // end if - - assignImplementation_toAServicesInterfaces( i_includingServicesId, - lhf_Search_CeFromTypeId( (*itServ).Type() ), - interface_2s_ExportingServices ); - } // end for -} - -void -SecondariesCalculator::assign_AsDerivedInterface( const Interface & i_rDerived ) -{ - ary::Dyn_StdConstIterator<ary::idl::CommentedRelation> - pHelp; - ary::idl::ifc_interface::attr::Get_Bases(pHelp, i_rDerived); - - for ( ary::StdConstIterator<ary::idl::CommentedRelation> & it = *pHelp; - it.operator bool(); - ++it ) - { - Interface * - pIfc = lhf_SearchInterface( (*it).Type() ); - if (pIfc == 0) - continue; - - insert_into2sList( *pIfc, - interface_2s_Derivations, - i_rDerived.CeId() ); - } // end for -} - -void -SecondariesCalculator::assign_AsDerivedStruct( const Struct & i_rDerived ) -{ - Type_id - nBase = i_rDerived.Base(); - if (nBase.IsValid()) - { - Struct * - pParent = lhf_SearchStruct(nBase); - if (pParent != 0) - { - insert_into2sList( *pParent, - struct_2s_Derivations, - i_rDerived.CeId() ); - } - } -} - -void -SecondariesCalculator::assign_AsDerivedException( const Exception & i_rDerived ) -{ - Type_id - nBase = i_rDerived.Base(); - if (nBase.IsValid()) - { - Exception * - pParent = lhf_SearchException(nBase); - if (pParent != 0) - { - insert_into2sList( *pParent, - exception_2s_Derivations, - i_rDerived.CeId() ); - } // end if - } // end if -} - -void -SecondariesCalculator::assignImplementation_toAServicesInterfaces( - Ce_id i_nImpl, - Ce_id i_nService, - E_2s_of_Interface i_eList ) -{ - if (NOT i_nService.IsValid()) - return; - Service * - pService = ary_cast<Service>( & my_CeStorage()[i_nService] ); - SglIfcService * - pSglIfcService = ary_cast<SglIfcService>( & my_CeStorage()[i_nService] ); - - if (pService != 0) - { - Dyn_StdConstIterator<CommentedRelation> - pSupportedInterfaces; - pService->Get_SupportedInterfaces(pSupportedInterfaces); - - for ( StdConstIterator<CommentedRelation> & - itInfc = *pSupportedInterfaces; - itInfc.operator bool(); - ++itInfc ) - { - recursive_AssignImplementation_toExportedInterface( i_nImpl, - (*itInfc).Type(), - i_eList ); - } // end for - } - else if (pSglIfcService != 0) - { - Type_id nBase = pSglIfcService->BaseInterface(); - recursive_AssignImplementation_toExportedInterface( i_nImpl, - nBase, - i_eList ); - } // end if -} - -void -SecondariesCalculator::recursive_AssignImplementation_toExportedInterface( - Ce_id i_nService, - Type_id i_nExportedInterface, - E_2s_of_Interface i_eList ) -{ - Interface * - pIfc = lhf_SearchInterface(i_nExportedInterface); - if (pIfc == 0) - return; - - insert_into2sUnique( *pIfc, - i_eList, - i_nService ); - Dyn_StdConstIterator<CommentedRelation> - pBases; - ary::idl::ifc_interface::attr::Get_Bases(pBases, *pIfc); - for ( StdConstIterator<CommentedRelation> & it = *pBases; - it.operator bool(); - ++it ) - { - recursive_AssignImplementation_toExportedInterface(i_nService, (*it).Type(), i_eList); - } -} - -void -SecondariesCalculator::recursive_AssignFunction_toCeAsReturn( Ce_id i_nFunction, - Type_id i_nReturnType ) -{ - Ce_id - nCe = lhf_Search_CeFromTypeId(i_nReturnType); - if (NOT nCe.IsValid()) - return; - - CodeEntity & - rCe = my_CeStorage()[nCe]; - switch (rCe.AryClass()) // KORR_FUTURE: make this faster, remove switch. - { - case Interface::class_id: - insert_into2sList( rCe, - interface_2s_AsReturns, - i_nFunction ); - break; - case Struct::class_id: - insert_into2sList( rCe, - struct_2s_AsReturns, - i_nFunction ); - break; - case Enum::class_id: - insert_into2sList( rCe, - enum_2s_AsReturns, - i_nFunction ); - break; - case Typedef::class_id: - insert_into2sList( rCe, - typedef_2s_AsReturns, - i_nFunction ); - recursive_AssignFunction_toCeAsReturn( i_nFunction, - static_cast< Typedef& >(rCe).DefiningType() ); - break; - // default: do nothing. - } -} - -void -SecondariesCalculator::recursive_AssignFunction_toCeAsParameter( Ce_id i_nFunction, - Type_id i_nParameterType ) -{ - Ce_id - nCe = lhf_Search_CeFromTypeId(i_nParameterType); - if (NOT nCe.IsValid()) - return; - - CodeEntity & - rCe = my_CeStorage()[nCe]; - switch (rCe.AryClass()) // KORR_FUTURE: make this faster, remove switch. - { - case Interface::class_id: - insert_into2sList( rCe, - interface_2s_AsParameters, - i_nFunction ); - break; - case Struct::class_id: - insert_into2sList( rCe, - struct_2s_AsParameters, - i_nFunction ); - break; - case Enum::class_id: - insert_into2sList( rCe, - enum_2s_AsParameters, - i_nFunction ); - break; - case Typedef::class_id: - insert_into2sList( rCe, - typedef_2s_AsParameters, - i_nFunction ); - recursive_AssignFunction_toCeAsParameter( i_nFunction, - static_cast< Typedef& >(rCe).DefiningType() ); - break; - // default: do nothing. - } -} - -void -SecondariesCalculator::recursive_AssignStructElement_toCeAsDataType( Ce_id i_nDataElement, - Type_id i_nDataType ) -{ - Ce_id - nCe = lhf_Search_CeFromTypeId(i_nDataType); - if (NOT nCe.IsValid()) - return; - - CodeEntity & - rCe = my_CeStorage()[nCe]; - switch (rCe.AryClass()) // KORR_FUTURE: make this faster, remove switch. - { - case Interface::class_id: - insert_into2sList( rCe, - interface_2s_AsDataTypes, - i_nDataElement ); - break; - case Struct::class_id: - insert_into2sList( rCe, - struct_2s_AsDataTypes, - i_nDataElement ); - break; - case Enum::class_id: - insert_into2sList( rCe, - enum_2s_AsDataTypes, - i_nDataElement ); - break; - case Typedef::class_id: - insert_into2sList( rCe, - typedef_2s_AsDataTypes, - i_nDataElement ); - recursive_AssignFunction_toCeAsParameter( i_nDataElement, - static_cast< Typedef& >(rCe).DefiningType() ); - break; - // default: do nothing. - } // end switch -} - -void -SecondariesCalculator::insert_into2sUnique( CodeEntity & o_out, - int i_listIndex, - Ce_id i_nCe ) -{ - std::vector<Ce_id> & - rOut = o_out.Secondaries().Access_List(i_listIndex); - if (std::find(rOut.begin(),rOut.end(),i_nCe) != rOut.end()) - return; - rOut.push_back(i_nCe); -} - -void -SecondariesCalculator::sort_All2s() -{ - OrderCeIdsByName - aIdOrdering(my_CeStorage()); - - for ( stg_iterator it = my_CeStorage().Begin(); - it != my_CeStorage().End(); - ++it ) - { - Ce_2s & - r2s = (*it).Secondaries(); - int iCount = r2s.CountXrefLists(); - for (int i = 0; i < iCount; ++i) - { - std::sort( r2s.Access_List(i).begin(), - r2s.Access_List(i).end(), - aIdOrdering ); - } // end for (i) - } // end for (it) -} - -void -SecondariesCalculator::Read_Links2DevManual( csv::bstream & i_file ) -{ - StreamLock aLine(300); - StreamStr & rLine = aLine(); - - - String sCurLink; - String sCurLinkUI; - E_LinkMode eCurMode = link2ref; - - int lineCount = 0; - const char * sLink = "LINK:"; - const char * sDescr = "DESCR:"; - const char * sTopic = "TOPIC:"; - const char * sRef = "REF:"; - const UINT8 cMaxASCIINumWhiteSpace = 32; - - while (NOT i_file.eod()) - { - ++lineCount; - - rLine.reset(); - rLine.operator_read_line(i_file); - - if ( *rLine.c_str() >= 'a' ) - { - assign_CurLink(rLine.begin(), sCurLink, sCurLinkUI, eCurMode == link2descr, lineCount); - } - else if ( strncmp(rLine.c_str(), sLink, strlen(sLink)) == 0 ) - { - sCurLink = rLine.c_str()+5; - sCurLinkUI.clear(); - } - else if ( strncmp(rLine.c_str(), sDescr, strlen(sDescr)) == 0 ) - { - sCurLinkUI = rLine.c_str()+6; - } - else if ( strncmp(rLine.c_str(), sTopic, strlen(sTopic)) == 0 ) - { - eCurMode = link2descr; - } - else if ( strncmp(rLine.c_str(), sRef, strlen(sRef)) == 0 ) - { - eCurMode = link2ref; - } - else if (static_cast<UINT8>(*rLine.c_str()) > cMaxASCIINumWhiteSpace) - { - assign_CurLink(rLine.begin(), sCurLink, sCurLinkUI, eCurMode == link2descr, lineCount); - } - // else - // Ignore empty line. - - } // end while -} - - - -} // namespace idl -} // namespace ary - -/* vim:set shiftwidth=4 softtabstop=4 expandtab: */ diff --git a/autodoc/source/ary/idl/i2s_calculator.hxx b/autodoc/source/ary/idl/i2s_calculator.hxx deleted file mode 100644 index dde4df5cb65c..000000000000 --- a/autodoc/source/ary/idl/i2s_calculator.hxx +++ /dev/null @@ -1,288 +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 ARY_IDL_I2S_CALCULATOR_HXX -#define ARY_IDL_I2S_CALCULATOR_HXX - - -// USED SERVICES - // BASE CLASSES -#include <cosv/tpl/processor.hxx> - // PARAMETERS -#include <ary/idl/i_types4idl.hxx> - - -namespace ary -{ -namespace idl -{ - class CeAdmin; - class Ce_Storage; - class TypeAdmin; - class Type_Storage; - class ExplicitType; - class Function; - class Interface; - class Property; - class Typedef; - class Service; - class Singleton; - class SglIfcService; - class SglIfcSingleton; - class Struct; - class StructElement; - class Exception; - class Ce_2s; -} -} - - - - - - -namespace ary -{ -namespace idl -{ - - -enum E_2s_of_Service -{ - service_2s_IncludingServices, - service_2s_InstantiatingSingletons -}; - -enum E_2s_of_Interface -{ - interface_2s_Derivations, - interface_2s_ExportingServices, - interface_2s_ExportingSingletons, - interface_2s_SynonymTypedefs, -// interface_2s_UsingTypedefs, - interface_2s_AsReturns, -// interface_2s_AsIndirectReturns, - interface_2s_AsParameters, -// interface_2s_AsIndirectParameters, - interface_2s_AsDataTypes -}; - -enum E_2s_of_Struct -{ - struct_2s_Derivations, - struct_2s_SynonymTypedefs, -// struct_2s_UsingTypedefs, - struct_2s_AsReturns, -// struct_2s_AsIndirectReturns, - struct_2s_AsParameters, -// struct_2s_AsIndirectParameters, - struct_2s_AsDataTypes -}; - -enum E_2s_of_Enum -{ - enum_2s_SynonymTypedefs, -// enum_2s_UsingTypedefs, - enum_2s_AsReturns, -// enum_2s_AsIndirectReturns, - enum_2s_AsParameters, -// enum_2s_AsIndirectParameters, - enum_2s_AsDataTypes -}; - -enum E_2s_of_Typedef -{ - typedef_2s_SynonymTypedefs, -// typedef_2s_UsingTypedefs, - typedef_2s_AsReturns, -// typedef_2s_AsIndirectReturns, - typedef_2s_AsParameters, -// typedef_2s_AsIndirectParameters, - typedef_2s_AsDataTypes -}; - -enum E_2s_of_Exceptions -{ - exception_2s_Derivations, - exception_2s_RaisingFunctions -}; - - - -class SPInst_asHost : public csv::ProcessorIfc, - public csv::ConstProcessor<Service>, - public csv::ConstProcessor<Interface>, - public csv::ConstProcessor<Struct>, - public csv::ConstProcessor<Exception>, - public csv::ConstProcessor<Typedef>, - public csv::ConstProcessor<Singleton>, - public csv::ConstProcessor<Function>, - public csv::ConstProcessor<StructElement>, - public csv::ConstProcessor<Property>, - public csv::ConstProcessor<SglIfcService>, - public csv::ConstProcessor<SglIfcSingleton> -{ -}; - - - - -/** This class scans the parsed data and produces several - secondary data like cross references and alphabetical indices. - - In this declaration "Secondaries" or "2s" mean those secondary data. - - @see Ce_2s -*/ -class SecondariesCalculator : public SPInst_asHost -{ - public: - // LIFECYCLE - SecondariesCalculator( - CeAdmin & i_ces, - TypeAdmin & i_types ); - virtual ~SecondariesCalculator(); - - // OPERATIONS - void CheckAllInterfaceBases(); - void Connect_Types2Ces(); - void Gather_CrossReferences(); - void Make_Links2DeveloperManual( - const String & i_devman_reffilepath ); - - private: - // Interface CeHost These are the points to gather cross - // references: - virtual void do_Process( - const Service & i_rData ); - virtual void do_Process( - const Interface & i_rData ); - virtual void do_Process( - const Struct & i_rData ); - virtual void do_Process( - const Exception & i_rData ); - virtual void do_Process( - const Typedef & i_rData ); - virtual void do_Process( - const Singleton & i_rData ); - virtual void do_Process( - const Function & i_rData ); - virtual void do_Process( - const StructElement & - i_rData ); - virtual void do_Process( - const Property & i_rData ); - virtual void do_Process( - const SglIfcService & - i_rData ); - virtual void do_Process( - const SglIfcSingleton & - i_rData ); - - // Locals - const Ce_Storage & my_CeStorage() const; - const Type_Storage & - my_TypeStorage() const; - Ce_Storage & my_CeStorage(); - Type_Storage & my_TypeStorage(); - - template <class DEST> - DEST * SearchCe4Type( - Type_id i_type ); - Ce_id lhf_Search_CeForType( - const ExplicitType & - i_rType ) const; - Ce_id lhf_Search_CeFromTypeId( - Type_id i_nType ) const; - Service * lhf_SearchService( - Type_id i_nServ ); - Interface * lhf_SearchInterface( - Type_id i_nIfc ); - Struct * lhf_SearchStruct( - Type_id i_nIfc ); - Exception * lhf_SearchException( - Type_id i_nIfc ); - void assign_CurLink( - char * i_text, - const String & i_link, - const String & i_linkUI, - bool i_isDescr, /// @descr true: description, false: reference. - int i_lineCount ); - void gather_Synonyms(); - void recursive_AssignAsSynonym( - Ce_id i_synonymousTypedefsId, - const Typedef & i_TypedefToCheck ); - void recursive_AssignIncludingService( - Ce_id i_includingServicesId, - const Service & i_ServiceToCheckItsIncludes ); - void assign_AsDerivedInterface( - const Interface & i_rDerived ); - void assign_AsDerivedStruct( - const Struct & i_rDerived ); - void assign_AsDerivedException( - const Exception & i_rDerived ); - void assignImplementation_toAServicesInterfaces( - Ce_id i_nImpl, - Ce_id i_nService, - E_2s_of_Interface i_eList ); - void recursive_AssignImplementation_toExportedInterface( - Ce_id i_nService, - Type_id i_nExportedInterface, - E_2s_of_Interface i_eList ); - void recursive_AssignFunction_toCeAsReturn( - Ce_id i_nFunction, - Type_id i_nReturnType ); - void recursive_AssignFunction_toCeAsParameter( - Ce_id i_nFunction, - Type_id i_nParameterType ); - - /** @param i_nDataElement - May be the ID of an struct element as well as an exception element - or a property. - */ - void recursive_AssignStructElement_toCeAsDataType( - Ce_id i_nDataElement, - Type_id i_nDataType ); - void insert_into2sList( - CodeEntity & o_out, - int i_listIndex, - Ce_id i_nCe ); - void insert_into2sUnique( - CodeEntity & o_out, - int i_listIndex, - Ce_id i_nCe ); - /// Sorts secondary production lists alphabetical. - void sort_All2s(); - - void Read_Links2DevManual( - csv::bstream & i_file ); - - // DATA - CeAdmin * pCes; - TypeAdmin * pTypes; -}; - - - - -} // namespace idl -} // namespace ary -#endif - -/* vim:set shiftwidth=4 softtabstop=4 expandtab: */ diff --git a/autodoc/source/ary/idl/i_attribute.cxx b/autodoc/source/ary/idl/i_attribute.cxx deleted file mode 100644 index 774c3694845b..000000000000 --- a/autodoc/source/ary/idl/i_attribute.cxx +++ /dev/null @@ -1,153 +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 . - */ - -#include <precomp.h> -#include <ary/idl/i_attribute.hxx> -#include <ary/idl/ik_attribute.hxx> - - -// NOT FULLY DECLARED SERVICES -#include <cosv/tpl/processor.hxx> -#include <ary/getncast.hxx> -#include <sci_impl.hxx> - - -namespace ary -{ -namespace idl -{ - - -Attribute::Attribute( const String & i_sName, - Ce_id i_nService, - Ce_id i_nModule, - Type_id i_nType, - bool i_bReadonly, - bool i_bBound ) - : sName(i_sName), - nOwner(i_nService), - nNameRoom(i_nModule), - nType(i_nType), - aGetExceptions(), - aSetExceptions(), - bReadonly(i_bReadonly), - bBound(i_bBound) -{ -} - -Attribute::~Attribute() -{ -} - - -void -Attribute::do_Accept(csv::ProcessorIfc & io_processor) const -{ - csv::CheckedCall(io_processor,*this); -} - -ClassId -Attribute::get_AryClass() const -{ - return class_id; -} - -const String & -Attribute::inq_LocalName() const -{ - return sName; -} - -Ce_id -Attribute::inq_NameRoom() const -{ - return nNameRoom; -} - -Ce_id -Attribute::inq_Owner() const -{ - return nOwner; -} - -E_SightLevel -Attribute::inq_SightLevel() const -{ - return sl_Member; -} - -namespace ifc_attribute -{ - -inline const Attribute & -attribute_cast( const CodeEntity & i_ce ) -{ - csv_assert( is_type<Attribute>(i_ce) ); - return static_cast< const Attribute& >(i_ce); -} - -bool -attr::HasAnyStereotype( const CodeEntity & i_ce ) -{ - const Attribute & rAttr = attribute_cast(i_ce); - return rAttr.bReadonly OR rAttr.bBound; -} - -bool -attr::IsReadOnly( const CodeEntity & i_ce ) -{ - return attribute_cast(i_ce).bReadonly; -} - -bool -attr::IsBound( const CodeEntity & i_ce ) -{ - return attribute_cast(i_ce).bBound; -} - -Type_id -attr::Type( const CodeEntity & i_ce ) -{ - return attribute_cast(i_ce).nType; -} - -void -attr::Get_GetExceptions( Dyn_TypeIterator & o_result, - const CodeEntity & i_ce ) -{ - o_result - = new SCI_Vector<Type_id>( attribute_cast(i_ce).aGetExceptions ); -} - -void -attr::Get_SetExceptions( Dyn_TypeIterator & o_result, - const CodeEntity & i_ce ) -{ - o_result - = new SCI_Vector<Type_id>( attribute_cast(i_ce).aSetExceptions ); -} - - -} // namespace ifc_attribute - - -} // namespace idl -} // namespace ary - -/* vim:set shiftwidth=4 softtabstop=4 expandtab: */ diff --git a/autodoc/source/ary/idl/i_ce.cxx b/autodoc/source/ary/idl/i_ce.cxx deleted file mode 100644 index a1076a355f0a..000000000000 --- a/autodoc/source/ary/idl/i_ce.cxx +++ /dev/null @@ -1,62 +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 . - */ - -#include <precomp.h> -#include <ary/idl/i_ce.hxx> - - -// NOT FULLY DEFINED SERVICES -#include <ary/doc/d_oldidldocu.hxx> -#include <ary/getncast.hxx> - - -namespace ary -{ -namespace idl -{ - -CodeEntity::CodeEntity() - : aDocu(), - p2s(0) -{ -} - -CodeEntity::~CodeEntity() -{ -} - -const Ce_2s & -CodeEntity::Secondaries() const -{ - return const_cast<CodeEntity*>(this)->Secondaries(); -} - -Ce_2s & -CodeEntity::Secondaries() -{ - if (p2s) - return *p2s; - p2s = Ce_2s::Create_(); - return *p2s; -} - -} // namespace idl -} // namespace ary - -/* vim:set shiftwidth=4 softtabstop=4 expandtab: */ diff --git a/autodoc/source/ary/idl/i_ce2s.cxx b/autodoc/source/ary/idl/i_ce2s.cxx deleted file mode 100644 index d002cd2868bc..000000000000 --- a/autodoc/source/ary/idl/i_ce2s.cxx +++ /dev/null @@ -1,78 +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 . - */ - -#include <precomp.h> -#include <ary/idl/i_ce.hxx> - - -// NOT FULLY DEFINED SERVICES -#include <cosv/tpl/tpltools.hxx> -#include <ary/doc/d_oldidldocu.hxx> -#include <ary/getncast.hxx> - - -namespace ary -{ -namespace idl -{ - -namespace -{ -const std::vector<Ce_id> C_sNullVector_Ce_ids; -} - - -Ce_2s::~Ce_2s() -{ - csv::erase_container_of_heap_ptrs(aXrefLists); -} - -DYN Ce_2s * -Ce_2s::Create_() -{ - return new Ce_2s; -} - - -std::vector<Ce_id> & -Ce_2s::Access_List( int i_indexOfList ) -{ - csv_assert(i_indexOfList >= 0 AND i_indexOfList < 1000); - - while (i_indexOfList >= (int) aXrefLists.size()) - { - aXrefLists.push_back(new std::vector<Ce_id>); - } - return *aXrefLists[i_indexOfList]; -} - -const std::vector<Ce_id> & -Ce_2s::List( int i_indexOfList ) const -{ - if (uintt(i_indexOfList) < aXrefLists.size()) - return *aXrefLists[i_indexOfList]; - else - return C_sNullVector_Ce_ids; -} - - -} // namespace idl -} // namespace ary - -/* vim:set shiftwidth=4 softtabstop=4 expandtab: */ diff --git a/autodoc/source/ary/idl/i_comrela.cxx b/autodoc/source/ary/idl/i_comrela.cxx deleted file mode 100644 index 337676b99630..000000000000 --- a/autodoc/source/ary/idl/i_comrela.cxx +++ /dev/null @@ -1,41 +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 . - */ - -#include <precomp.h> -#include <ary/idl/i_comrela.hxx> - - -// NOT FULLY DEFINED SERVICES -#include <ary/ary.hxx> -#include <ary/idl/i_gate.hxx> -#include <ary/idl/ip_ce.hxx> -#include <ary/idl/ip_type.hxx> - - -namespace ary -{ -namespace idl -{ - -// KORR_FUTURE Currently unneeded file. May become useful later. - -} // namespace idl -} // namespace ary - -/* vim:set shiftwidth=4 softtabstop=4 expandtab: */ diff --git a/autodoc/source/ary/idl/i_constant.cxx b/autodoc/source/ary/idl/i_constant.cxx deleted file mode 100644 index edef2aece14c..000000000000 --- a/autodoc/source/ary/idl/i_constant.cxx +++ /dev/null @@ -1,117 +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 . - */ - -#include <precomp.h> -#include <ary/idl/i_constant.hxx> - - -// NOT FULLY DECLARED SERVICES -#include <cosv/tpl/processor.hxx> -#include <ary/idl/ik_constant.hxx> - - -namespace ary -{ -namespace idl -{ - -Constant::Constant( const String & i_sName, - Ce_id i_nOwner, - Ce_id i_nNameRoom, - Type_id i_nType, - const String & i_sInitValue ) - : sName(i_sName), - nNameRoom(i_nNameRoom), - nOwner(i_nOwner), - nType(i_nType), - sInitValue(i_sInitValue) -{ -} - -Constant::~Constant() -{ -} - -void -Constant::do_Accept( csv::ProcessorIfc & io_processor ) const -{ - csv::CheckedCall(io_processor, *this); -} - - -ClassId -Constant::get_AryClass() const -{ - return class_id; -} - -const String & -Constant::inq_LocalName() const -{ - return sName; -} - -Ce_id -Constant::inq_NameRoom() const -{ - return nNameRoom; -} - -Ce_id -Constant::inq_Owner() const -{ - return nOwner; -} - -E_SightLevel -Constant::inq_SightLevel() const -{ - return sl_Member; -} - - -namespace ifc_constant -{ - -inline const Constant & -constant_cast( const CodeEntity & i_ce ) -{ - csv_assert( i_ce.AryClass() == Constant::class_id ); - return static_cast< const Constant& >(i_ce); -} - -Type_id -attr::Type( const CodeEntity & i_ce ) -{ - return constant_cast(i_ce).nType; -} - -const String & -attr::Value( const CodeEntity & i_ce ) -{ - return constant_cast(i_ce).sInitValue; -} - -} // namespace ifc_constant - - -} // namespace idl -} // namespace ary - -/* vim:set shiftwidth=4 softtabstop=4 expandtab: */ diff --git a/autodoc/source/ary/idl/i_constgroup.cxx b/autodoc/source/ary/idl/i_constgroup.cxx deleted file mode 100644 index 2e3ec84d2ceb..000000000000 --- a/autodoc/source/ary/idl/i_constgroup.cxx +++ /dev/null @@ -1,108 +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 . - */ - -#include <precomp.h> -#include <ary/idl/i_constgroup.hxx> -#include <ary/idl/ik_constgroup.hxx> - - -// NOT FULLY DECLARED SERVICES -#include <cosv/tpl/processor.hxx> -#include <sci_impl.hxx> - - -namespace ary -{ -namespace idl -{ - - -ConstantsGroup::ConstantsGroup( const String & i_sName, - Ce_id i_nModule ) - : sName(i_sName), - nModule(i_nModule), - aConstants() -{ -} - -ConstantsGroup::~ConstantsGroup() -{ -} - -void -ConstantsGroup::do_Accept( csv::ProcessorIfc & io_processor ) const -{ - csv::CheckedCall(io_processor, *this); -} - -ClassId -ConstantsGroup::get_AryClass() const -{ - return class_id; -} - -const String & -ConstantsGroup::inq_LocalName() const -{ - return sName; -} - -Ce_id -ConstantsGroup::inq_NameRoom() const -{ - return nModule; -} - -Ce_id -ConstantsGroup::inq_Owner() const -{ - return nModule; -} - -E_SightLevel -ConstantsGroup::inq_SightLevel() const -{ - return sl_File; -} - - -namespace ifc_constgroup -{ - -inline const ConstantsGroup & -constgroup_cast( const CodeEntity & i_ce ) -{ - csv_assert( i_ce.AryClass() == ConstantsGroup::class_id ); - return static_cast< const ConstantsGroup& >(i_ce); -} - -void -attr::Get_Constants( Dyn_CeIterator & o_result, - const CodeEntity & i_ce ) -{ - o_result = new SCI_Vector<Ce_id>(constgroup_cast(i_ce).aConstants); -} - -} // namespace ifc_constgroup - - -} // namespace idl -} // namespace ary - -/* vim:set shiftwidth=4 softtabstop=4 expandtab: */ diff --git a/autodoc/source/ary/idl/i_enum.cxx b/autodoc/source/ary/idl/i_enum.cxx deleted file mode 100644 index eb33ac7aee53..000000000000 --- a/autodoc/source/ary/idl/i_enum.cxx +++ /dev/null @@ -1,137 +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 . - */ - -#include <precomp.h> -#include <ary/idl/i_enum.hxx> -#include <ary/idl/ik_enum.hxx> - - -// NOT FULLY DECLARED SERVICES -#include <cosv/tpl/processor.hxx> -#include <sci_impl.hxx> -#include "i2s_calculator.hxx" - - -namespace ary -{ -namespace idl -{ - -Enum::Enum( const String & i_sName, - Ce_id i_nOwner ) - : sName(i_sName), - nOwner(i_nOwner), - aValues() -{ -} - -Enum::~Enum() -{ -} - -void -Enum::do_Accept( csv::ProcessorIfc & io_processor ) const -{ - csv::CheckedCall(io_processor, *this); -} - -ClassId -Enum::get_AryClass() const -{ - return class_id; -} - -const String & -Enum::inq_LocalName() const -{ - return sName; -} - -Ce_id -Enum::inq_NameRoom() const -{ - return nOwner; -} - -Ce_id -Enum::inq_Owner() const -{ - return nOwner; -} - -E_SightLevel -Enum::inq_SightLevel() const -{ - return sl_File; -} - - -namespace ifc_enum -{ - -inline const Enum & -enum_cast( const CodeEntity & i_ce ) -{ - csv_assert( i_ce.AryClass() == Enum::class_id ); - return static_cast< const Enum& >(i_ce); -} - -void -attr::Get_Values( Dyn_CeIterator & o_result, - const CodeEntity & i_ce ) -{ - o_result = new SCI_Vector<Ce_id>(enum_cast(i_ce).aValues); -} - - -void -xref::Get_SynonymTypedefs( Dyn_CeIterator & o_result, - const CodeEntity & i_ce ) -{ - o_result = new SCI_Vector<Ce_id>(i_ce.Secondaries().List(enum_2s_SynonymTypedefs)); -} - -void -xref::Get_AsReturns( Dyn_CeIterator & o_result, - const CodeEntity & i_ce ) -{ - o_result = new SCI_Vector<Ce_id>(i_ce.Secondaries().List(enum_2s_AsReturns)); -} - -void -xref::Get_AsParameters( Dyn_CeIterator & o_result, - const CodeEntity & i_ce ) -{ - o_result = new SCI_Vector<Ce_id>(i_ce.Secondaries().List(enum_2s_AsParameters)); -} - -void -xref::Get_AsDataTypes( Dyn_CeIterator & o_result, - const CodeEntity & i_ce ) -{ - o_result = new SCI_Vector<Ce_id>(i_ce.Secondaries().List(enum_2s_AsDataTypes)); -} - -} // namespace ifc_enum - - -} // namespace idl -} // namespace ary - -/* vim:set shiftwidth=4 softtabstop=4 expandtab: */ diff --git a/autodoc/source/ary/idl/i_enumvalue.cxx b/autodoc/source/ary/idl/i_enumvalue.cxx deleted file mode 100644 index 795c743c723f..000000000000 --- a/autodoc/source/ary/idl/i_enumvalue.cxx +++ /dev/null @@ -1,110 +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 . - */ - -#include <precomp.h> -#include <ary/idl/i_enumvalue.hxx> - - -// NOT FULLY DECLARED SERVICES -#include <cosv/tpl/processor.hxx> -#include <ary/idl/ik_enumvalue.hxx> - - -namespace ary -{ -namespace idl -{ - -EnumValue::EnumValue( const String & i_sName, - Ce_id i_nOwner, - Ce_id i_nNameRoom, - const String & i_sInitValue ) - : sName(i_sName), - nOwner(i_nOwner), - nNameRoom(i_nNameRoom), - sValue(i_sInitValue) -{ -} - -EnumValue::~EnumValue() -{ -} - -void -EnumValue::do_Accept( csv::ProcessorIfc & io_processor ) const -{ - csv::CheckedCall(io_processor, *this); -} - -ClassId -EnumValue::get_AryClass() const -{ - return class_id; -} - -const String & -EnumValue::inq_LocalName() const -{ - return sName; -} - -Ce_id -EnumValue::inq_NameRoom() const -{ - return nNameRoom; -} - -Ce_id -EnumValue::inq_Owner() const -{ - return nOwner; -} - -E_SightLevel -EnumValue::inq_SightLevel() const -{ - return sl_Member; -} - - - -namespace ifc_enumvalue -{ - -inline const EnumValue & -enumvalue_cast( const CodeEntity & i_ce ) -{ - csv_assert( i_ce.AryClass() == EnumValue::class_id ); - return static_cast< const EnumValue& >(i_ce); -} - -const String & -attr::Value( const CodeEntity & i_ce ) -{ - return enumvalue_cast(i_ce).sValue; -} - - -} // namespace ifc_enumvalue - - -} // namespace idl -} // namespace ary - -/* vim:set shiftwidth=4 softtabstop=4 expandtab: */ diff --git a/autodoc/source/ary/idl/i_exception.cxx b/autodoc/source/ary/idl/i_exception.cxx deleted file mode 100644 index 234e0744ccd5..000000000000 --- a/autodoc/source/ary/idl/i_exception.cxx +++ /dev/null @@ -1,133 +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 . - */ - -#include <precomp.h> -#include <ary/idl/i_exception.hxx> -#include <ary/idl/ik_exception.hxx> - - -// NOT FULLY DECLARED SERVICES -#include <cosv/tpl/processor.hxx> -#include <sci_impl.hxx> -#include "i2s_calculator.hxx" - - - -namespace ary -{ -namespace idl -{ - -Exception::Exception( const String & i_sName, - Ce_id i_nOwner, - Type_id i_nBase ) - : sName(i_sName), - nOwner(i_nOwner), - nBase(i_nBase), - aElements() -{ -} - -Exception::~Exception() -{ -} - -void -Exception::do_Accept( csv::ProcessorIfc & io_processor ) const -{ - csv::CheckedCall(io_processor, *this); -} - -ClassId -Exception::get_AryClass() const -{ - return class_id; -} - -const String & -Exception::inq_LocalName() const -{ - return sName; -} - -Ce_id -Exception::inq_NameRoom() const -{ - return nOwner; -} - -Ce_id -Exception::inq_Owner() const -{ - return nOwner; -} - -E_SightLevel -Exception::inq_SightLevel() const -{ - return sl_File; -} - - -namespace ifc_exception -{ - -inline const Exception & -exception_cast( const CodeEntity & i_ce ) -{ - csv_assert( i_ce.AryClass() == Exception::class_id ); - return static_cast< const Exception& >(i_ce); -} - -Type_id -attr::Base( const CodeEntity & i_ce ) -{ - return exception_cast(i_ce).nBase; -} - -void -attr::Get_Elements( Dyn_CeIterator & o_result, - const CodeEntity & i_ce ) -{ - o_result = new SCI_Vector<Ce_id>( exception_cast(i_ce).aElements ); -} - - -void -xref::Get_Derivations( Dyn_CeIterator & o_result, - const CodeEntity & i_ce ) -{ - o_result = new SCI_Vector<Ce_id>(i_ce.Secondaries().List(exception_2s_Derivations)); -} - -void -xref::Get_RaisingFunctions( Dyn_CeIterator & o_result, - const CodeEntity & i_ce ) -{ - o_result = new SCI_Vector<Ce_id>(i_ce.Secondaries().List(exception_2s_RaisingFunctions)); -} - - -} // namespace ifc_exception - - -} // namespace idl -} // namespace ary - -/* vim:set shiftwidth=4 softtabstop=4 expandtab: */ diff --git a/autodoc/source/ary/idl/i_function.cxx b/autodoc/source/ary/idl/i_function.cxx deleted file mode 100644 index 084b91ecbad1..000000000000 --- a/autodoc/source/ary/idl/i_function.cxx +++ /dev/null @@ -1,159 +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 . - */ - -#include <precomp.h> -#include <ary/idl/i_function.hxx> - - -// NOT FULLY DECLARED SERVICES -#include <cosv/tpl/processor.hxx> -#include <sci_impl.hxx> - - - -namespace ary -{ -namespace idl -{ - -Function::Function( const String & i_sName, - Ce_id i_nOwner, - Ce_id i_nNameRoom, - Type_id i_nReturnType, - bool i_bOneWay ) - : sName(i_sName), - nOwner(i_nOwner), - nNameRoom(i_nNameRoom), - nReturnType(i_nReturnType), - aParameters(), - aExceptions(), - bOneWay(i_bOneWay), - bEllipse(false) -{ -} - -Function::Function( const String & i_sName, - Ce_id i_nOwner, - Ce_id i_nNameRoom ) - : sName(i_sName), - nOwner(i_nOwner), - nNameRoom(i_nNameRoom), - nReturnType(0), - aParameters(), - aExceptions(), - bOneWay(false), - bEllipse(false) -{ -} - -Function::~Function() -{ -} - -void -Function::do_Accept( csv::ProcessorIfc & io_processor ) const -{ - csv::CheckedCall(io_processor, *this); -} - -ClassId -Function::get_AryClass() const -{ - return class_id; -} - -const String & -Function::inq_LocalName() const -{ - return sName; -} - -Ce_id -Function::inq_NameRoom() const -{ - return nNameRoom; -} - -Ce_id -Function::inq_Owner() const -{ - return nOwner; -} - -E_SightLevel -Function::inq_SightLevel() const -{ - return sl_Member; -} - - -namespace ifc_function -{ - -inline const Function & -function_cast( const CodeEntity & i_ce ) -{ - csv_assert( i_ce.AryClass() == Function::class_id ); - return static_cast< const Function& >(i_ce); -} - -Type_id -attr::ReturnType( const CodeEntity & i_ce ) -{ - return function_cast(i_ce).nReturnType; -} - -bool -attr::IsOneway( const CodeEntity & i_ce ) -{ - return function_cast(i_ce).bOneWay; -} - -bool -attr::HasEllipse( const CodeEntity & i_ce ) -{ - return function_cast(i_ce).bEllipse; -} - -void -attr::Get_Parameters( Dyn_StdConstIterator<ary::idl::Parameter> & o_result, - const CodeEntity & i_ce ) -{ - o_result - = new SCI_Vector<Parameter>( function_cast(i_ce).aParameters ); -} - -void -attr::Get_Exceptions( Dyn_TypeIterator & o_result, - const CodeEntity & i_ce ) -{ - o_result - = new SCI_Vector<Type_id>( function_cast(i_ce).aExceptions ); -} - - - - - -} // namespace ifc_function - -} // namespace idl -} // namespace ary - -/* vim:set shiftwidth=4 softtabstop=4 expandtab: */ diff --git a/autodoc/source/ary/idl/i_interface.cxx b/autodoc/source/ary/idl/i_interface.cxx deleted file mode 100644 index 6c74fe95d2fb..000000000000 --- a/autodoc/source/ary/idl/i_interface.cxx +++ /dev/null @@ -1,190 +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 . - */ - -#include <precomp.h> -#include <ary/idl/i_interface.hxx> - - -// NOT FULLY DECLARED SERVICES -#include <cosv/tpl/processor.hxx> -#include <ary/idl/ik_interface.hxx> -#include <ary/doc/d_oldidldocu.hxx> -#include <sci_impl.hxx> -#include "i2s_calculator.hxx" - - -namespace ary -{ -namespace idl -{ - - -class Interface_2s -{ -}; - - -Interface::Interface( const String & i_sName, - Ce_id i_nOwner ) - : sName(i_sName), - nOwner(i_nOwner), - aBases(), - aFunctions(), - aAttributes(), - p2s() -{ -} - -Interface::~Interface() -{ - for ( RelationList::iterator it = aBases.begin(); - it != aBases.end(); - ++it ) - { - delete (*it).Info(); - } -} - -void -Interface::do_Accept( csv::ProcessorIfc & io_processor ) const -{ - csv::CheckedCall(io_processor, *this); -} - -ClassId -Interface::get_AryClass() const -{ - return class_id; -} - -const String & -Interface::inq_LocalName() const -{ - return sName; -} - -Ce_id -Interface::inq_NameRoom() const -{ - return nOwner; -} - -Ce_id -Interface::inq_Owner() const -{ - return nOwner; -} - -E_SightLevel -Interface::inq_SightLevel() const -{ - return sl_File; -} - - -namespace ifc_interface -{ - -inline const Interface & -interface_cast( const CodeEntity & i_ce ) -{ - csv_assert( i_ce.AryClass() == Interface::class_id ); - return static_cast< const Interface& >(i_ce); -} - -void -attr::Get_Bases( Dyn_StdConstIterator<CommentedRelation> & o_result, - const CodeEntity & i_ce ) -{ - o_result = new SCI_Vector<CommentedRelation>(interface_cast(i_ce).aBases); -} - -void -attr::Get_Functions( Dyn_CeIterator & o_result, - const CodeEntity & i_ce ) -{ - o_result = new SCI_Vector<Ce_id>(interface_cast(i_ce).aFunctions); -} - -void -attr::Get_Attributes( Dyn_CeIterator & o_result, - const CodeEntity & i_ce ) -{ - o_result = new SCI_Vector<Ce_id>(interface_cast(i_ce).aAttributes); -} - -void -xref::Get_Derivations( Dyn_CeIterator & o_result, - const CodeEntity & i_ce ) -{ - o_result = new SCI_Vector<Ce_id>(i_ce.Secondaries().List(interface_2s_Derivations)); -} - -void -xref::Get_SynonymTypedefs( Dyn_CeIterator & o_result, - const CodeEntity & i_ce ) -{ - o_result = new SCI_Vector<Ce_id>(i_ce.Secondaries().List(interface_2s_SynonymTypedefs)); -} - -void -xref::Get_ExportingServices( Dyn_CeIterator & o_result, - const CodeEntity & i_ce ) -{ - o_result = new SCI_Vector<Ce_id>(i_ce.Secondaries().List(interface_2s_ExportingServices)); -} - -void -xref::Get_ExportingSingletons( Dyn_CeIterator & o_result, - const CodeEntity & i_ce ) -{ - o_result = new SCI_Vector<Ce_id>(i_ce.Secondaries().List(interface_2s_ExportingSingletons)); -} - -void -xref::Get_AsReturns( Dyn_CeIterator & o_result, - const CodeEntity & i_ce ) -{ - o_result = new SCI_Vector<Ce_id>(i_ce.Secondaries().List(interface_2s_AsReturns)); -} - -void -xref::Get_AsParameters( Dyn_CeIterator & o_result, - const CodeEntity & i_ce ) -{ - o_result = new SCI_Vector<Ce_id>(i_ce.Secondaries().List(interface_2s_AsParameters)); -} - -void -xref::Get_AsDataTypes( Dyn_CeIterator & o_result, - const CodeEntity & i_ce ) -{ - o_result = new SCI_Vector<Ce_id>(i_ce.Secondaries().List(interface_2s_AsDataTypes)); -} - - - - -} // namespace ifc_interface - - -} // namespace idl -} // namespace ary - -/* vim:set shiftwidth=4 softtabstop=4 expandtab: */ diff --git a/autodoc/source/ary/idl/i_module.cxx b/autodoc/source/ary/idl/i_module.cxx deleted file mode 100644 index a6a7b871b377..000000000000 --- a/autodoc/source/ary/idl/i_module.cxx +++ /dev/null @@ -1,197 +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 . - */ - -#include <precomp.h> -#include <ary/idl/i_module.hxx> -#include <ary/idl/ik_module.hxx> - -// NOT FULLY DECLARED SERVICES -#include <cosv/tpl/processor.hxx> -#include <ary/idl/i_gate.hxx> -#include <ary/idl/i_service.hxx> -#include <ary/idl/i_interface.hxx> -#include <ary/idl/i_struct.hxx> -#include <ary/idl/i_exception.hxx> -#include <ary/idl/i_enum.hxx> -#include <ary/idl/i_typedef.hxx> -#include <ary/idl/i_constgroup.hxx> -#include <ary/idl/i_singleton.hxx> -#include <ary/idl/i_siservice.hxx> -#include <ary/idl/i_sisingleton.hxx> -#include <ary/idl/ip_ce.hxx> -#include <nametreenode.hxx> - - -namespace ary -{ -namespace idl -{ - -Module::Module() - : pImpl( new NameTreeNode<Ce_id> ) -{ -} - -Module::Module( const String & i_sName, - const Module & i_rParent ) - : pImpl( new NameTreeNode<Ce_id>( i_sName, - *i_rParent.pImpl, - i_rParent.CeId() ) ) -{ -} - -Module::~Module() -{ -} - -void -Module::Add_Name( const String & i_sName, - Ce_id i_nCodeEntity ) -{ - pImpl->Add_Name(i_sName, i_nCodeEntity); -} - -Ce_id -Module::Search_Name( const String & i_sName ) const -{ - return pImpl->Search_Name(i_sName); -} - -void -Module::Get_Names( Dyn_StdConstIterator<Ce_id> & o_rResult ) const -{ - pImpl->Get_Names( o_rResult ); -} - -void -Module::do_Accept( csv::ProcessorIfc & io_processor ) const -{ - csv::CheckedCall(io_processor, *this); -} - -ClassId -Module::get_AryClass() const -{ - return class_id; -} - -const String & -Module::inq_LocalName() const -{ - return pImpl->Name(); -} - -Ce_id -Module::inq_NameRoom() const -{ - return pImpl->Parent(); -} - -Ce_id -Module::inq_Owner() const -{ - return pImpl->Parent(); -} - -E_SightLevel -Module::inq_SightLevel() const -{ - return sl_Module; -} - - -namespace ifc_module -{ - -inline const Module & -module_cast( const CodeEntity & i_ce ) -{ - csv_assert( i_ce.AryClass() == Module::class_id ); - return static_cast< const Module& >(i_ce); -} - -typedef NameTreeNode<Ce_id>::Map_LocalNames NameMap; - -void -attr::Get_AllChildrenSeparated( std::vector< const CodeEntity* > & o_nestedModules, - std::vector< const CodeEntity* > & o_services, - std::vector< const CodeEntity* > & o_interfaces, - std::vector< const CodeEntity* > & o_structs, - std::vector< const CodeEntity* > & o_exceptions, - std::vector< const CodeEntity* > & o_enums, - std::vector< const CodeEntity* > & o_typedefs, - std::vector< const CodeEntity* > & o_constantGroups, - std::vector< const CodeEntity* > & o_singletons, - const CePilot & i_pilot, - const CodeEntity & i_ce ) -{ - const CodeEntity * - pCe = 0; - NameMap::const_iterator - itEnd = module_cast(i_ce).pImpl->LocalNames().end(); - for ( NameMap::const_iterator - it = module_cast(i_ce).pImpl->LocalNames().begin(); - it != itEnd; - ++it ) - { - pCe = &i_pilot.Find_Ce( (*it).second ); - switch (pCe->AryClass()) - { - case Module::class_id: - o_nestedModules.push_back(pCe); - break; - case SglIfcService::class_id: - case Service::class_id: - o_services.push_back(pCe); - break; - case Interface::class_id: - o_interfaces.push_back(pCe); - break; - case Struct::class_id: - o_structs.push_back(pCe); - break; - case Exception::class_id: - o_exceptions.push_back(pCe); - break; - case Enum::class_id: - o_enums.push_back(pCe); - break; - case Typedef::class_id: - o_typedefs.push_back(pCe); - break; - case ConstantsGroup::class_id: - o_constantGroups.push_back(pCe); - break; - case SglIfcSingleton::class_id: - case Singleton::class_id: - o_singletons.push_back(pCe); - break; - } - } // end for -} - - -} // namespace ifc_module - - - -} // namespace idl -} // namespace ary - -/* vim:set shiftwidth=4 softtabstop=4 expandtab: */ diff --git a/autodoc/source/ary/idl/i_namelookup.cxx b/autodoc/source/ary/idl/i_namelookup.cxx deleted file mode 100644 index 9a4db34bd290..000000000000 --- a/autodoc/source/ary/idl/i_namelookup.cxx +++ /dev/null @@ -1,56 +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 . - */ - -#include <precomp.h> -#include <ary/idl/i_namelookup.hxx> - -// NOT FULLY DECLARED SERVICES -#include <sci_impl.hxx> - -namespace ary -{ -namespace idl -{ - -NameLookup::NameLookup() - : aNames() -{ -} - -NameLookup::~NameLookup() -{ -} - -void -NameLookup::Add_Name( const String & i_name, - Ce_id i_id, - ClassId i_class, - Ce_id i_owner ) -{ - aNames.insert( std::pair< const String, NameProperties>( - i_name, - NameProperties( i_id, - i_class, - i_owner ))); -} - -} // namespace idl -} // namespace ary - -/* vim:set shiftwidth=4 softtabstop=4 expandtab: */ diff --git a/autodoc/source/ary/idl/i_nnfinder.hxx b/autodoc/source/ary/idl/i_nnfinder.hxx deleted file mode 100644 index e5239158ecd4..000000000000 --- a/autodoc/source/ary/idl/i_nnfinder.hxx +++ /dev/null @@ -1,112 +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 ARY_IDL_NNFINDER_HXX -#define ARY_IDL_NNFINDER_HXX - -// USED SERVICES -#include "is_ce.hxx" - - - - -namespace ary -{ -namespace idl -{ - - -/** Gives context info for tree search functions. - - @collab ->ary::Search_SubTree<>() - @collab ->ary::Search_SubTree_UpTillRoot<>() -*/ -class Find_ModuleNode -{ - public: - typedef Ce_id id_type; - typedef StringVector::const_iterator name_iterator; - - // LIFECYCLE - Find_ModuleNode( - const Ce_Storage & i_rStorage, - name_iterator it_begin, - name_iterator it_end, - const String & i_sName ) - : rStorage(i_rStorage), - itBegin(it_begin), - itEnd(it_end), - sName2Search(i_sName) { if (itBegin != itEnd ? (*itBegin).empty() : false) ++itBegin; } - // OPERATIONS - const Module * operator()( - id_type i_id ) const - { return i_id.IsValid() - ? & ary_cast<Module>(rStorage[i_id]) - : 0; } - - name_iterator Begin() const { return itBegin; } - name_iterator End() const { return itEnd; } - const String & Name2Search() const { return sName2Search; } - - private: - // DATA - const Ce_Storage & rStorage; - name_iterator itBegin; - name_iterator itEnd; - String sName2Search; -}; - - - - -class Types_forSetCe_Id -{ - public: - typedef Ce_id element_type; - typedef Ce_Storage find_type; - - // KORR_FUTURE: Check, if this sorting is right or the ary standard - // sorting should be used. - struct sort_type - { - sort_type( - const find_type & i_rFinder ) - : rFinder(i_rFinder) {} - bool operator()( - const element_type & - i_r1, - const element_type & - i_r2 ) const - { - return rFinder[i_r1].LocalName() - < rFinder[i_r2].LocalName(); - } - - private: - const find_type & rFinder; - - }; -}; - - -} // namespace idl -} // namespace ary -#endif - -/* vim:set shiftwidth=4 softtabstop=4 expandtab: */ diff --git a/autodoc/source/ary/idl/i_param.cxx b/autodoc/source/ary/idl/i_param.cxx deleted file mode 100644 index 312652226758..000000000000 --- a/autodoc/source/ary/idl/i_param.cxx +++ /dev/null @@ -1,51 +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 . - */ - -#include <precomp.h> -#include <ary/idl/i_param.hxx> - - -// NOT FULLY DEFINED SERVICES - - - -namespace ary -{ -namespace idl -{ - -Parameter::Parameter( const String & i_sName, - Type_id i_nType, - E_ParameterDirection i_eDirection ) - : sName(i_sName), - nType(i_nType), - eDirection(i_eDirection) -{ -} - -Parameter::~Parameter() -{ -} - - - -} // namespace idl -} // namespace ary - -/* vim:set shiftwidth=4 softtabstop=4 expandtab: */ diff --git a/autodoc/source/ary/idl/i_property.cxx b/autodoc/source/ary/idl/i_property.cxx deleted file mode 100644 index dfbd0a277bbc..000000000000 --- a/autodoc/source/ary/idl/i_property.cxx +++ /dev/null @@ -1,165 +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 . - */ - -#include <precomp.h> -#include <ary/idl/i_property.hxx> -#include <ary/idl/ik_property.hxx> - - -// NOT FULLY DECLARED SERVICES -#include <cosv/tpl/processor.hxx> - - -namespace ary -{ -namespace idl -{ - - -Property::Property( const String & i_sName, - Ce_id i_nService, - Ce_id i_nModule, - Type_id i_nType, - Stereotypes i_stereotypes ) - : sName(i_sName), - nOwner(i_nService), - nNameRoom(i_nModule), - nType(i_nType), - aStereotypes(i_stereotypes) -{ -} - -Property::~Property() -{ -} - - -void -Property::do_Accept( csv::ProcessorIfc & io_processor ) const -{ - csv::CheckedCall(io_processor, *this); -} - -ClassId -Property::get_AryClass() const -{ - return class_id; -} - -const String & -Property::inq_LocalName() const -{ - return sName; -} - -Ce_id -Property::inq_NameRoom() const -{ - return nNameRoom; -} - -Ce_id -Property::inq_Owner() const -{ - return nOwner; -} - -E_SightLevel -Property::inq_SightLevel() const -{ - return sl_Member; -} - -namespace ifc_property -{ - -inline const Property & -property_cast( const CodeEntity & i_ce ) -{ - csv_assert( i_ce.AryClass() == Property::class_id ); - return static_cast< const Property& >(i_ce); -} - -bool -attr::HasAnyStereotype( const CodeEntity & i_ce ) -{ - return property_cast(i_ce).aStereotypes.HasAny(); -} - -bool -attr::IsReadOnly( const CodeEntity & i_ce ) -{ - return property_cast(i_ce).aStereotypes.IsReadOnly(); -} - -bool -attr::IsBound( const CodeEntity & i_ce ) -{ - return property_cast(i_ce).aStereotypes.IsBound(); -} - -bool -attr::IsConstrained( const CodeEntity & i_ce ) -{ - return property_cast(i_ce).aStereotypes.IsConstrained(); -} - -bool -attr::IsMayBeAmbiguous( const CodeEntity & i_ce ) -{ - return property_cast(i_ce).aStereotypes.IsMayBeAmbiguous(); -} - -bool -attr::IsMayBeDefault( const CodeEntity & i_ce ) -{ - return property_cast(i_ce).aStereotypes.IsMayBeDefault(); -} - -bool -attr::IsMayBeVoid( const CodeEntity & i_ce ) -{ - return property_cast(i_ce).aStereotypes.IsMayBeVoid(); -} - -bool -attr::IsRemovable( const CodeEntity & i_ce ) -{ - return property_cast(i_ce).aStereotypes.IsRemovable(); -} - -bool -attr::IsTransient( const CodeEntity & i_ce ) -{ - return property_cast(i_ce).aStereotypes.IsTransient(); -} - -Type_id -attr::Type( const CodeEntity & i_ce ) -{ - return property_cast(i_ce).nType; -} - -} // namespace ifc_property - - -} // namespace idl -} // namespace ary - -/* vim:set shiftwidth=4 softtabstop=4 expandtab: */ diff --git a/autodoc/source/ary/idl/i_reposypart.cxx b/autodoc/source/ary/idl/i_reposypart.cxx deleted file mode 100644 index 62a7d51fdee0..000000000000 --- a/autodoc/source/ary/idl/i_reposypart.cxx +++ /dev/null @@ -1,112 +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 . - */ - -#include <precomp.h> -#include "i_reposypart.hxx" - - -// NOT FULLY DEFINED SERVICES -#include <ary/idl/i_namelookup.hxx> -#include <idl_internalgate.hxx> -#include "ia_ce.hxx" -#include "ia_type.hxx" -#include "i2s_calculator.hxx" -#include "is_ce.hxx" -#include "is_type.hxx" - - - - -namespace ary -{ -namespace idl -{ - - -DYN InternalGate & -InternalGate::Create_Partition_() -{ - return *new RepositoryPartition; -} - - - -RepositoryPartition::RepositoryPartition() - : pCes(0), - pTypes(0), - pNamesDictionary(new NameLookup) -{ - pTypes = new TypeAdmin; - pCes = new CeAdmin(*pNamesDictionary, *pTypes); -} - -RepositoryPartition::~RepositoryPartition() -{ -} - -void -RepositoryPartition::Calculate_AllSecondaryInformation( - const String & i_devman_reffilepath ) -{ - // KORR_FUTURE - // Forward the options from here. - - SecondariesCalculator - secalc(*pCes,*pTypes); - - secalc.CheckAllInterfaceBases(); - secalc.Connect_Types2Ces(); - secalc.Gather_CrossReferences(); - - if ( NOT i_devman_reffilepath.empty() ) - { - secalc.Make_Links2DeveloperManual(i_devman_reffilepath); - } -} - -const CePilot & -RepositoryPartition::Ces() const -{ - return *pCes; -} - -const TypePilot & -RepositoryPartition::Types() const -{ - return *pTypes; -} - -CePilot & -RepositoryPartition::Ces() -{ - return *pCes; -} - -TypePilot & -RepositoryPartition::Types() -{ - return *pTypes; -} - - - -} // namespace idl -} // namespace ary - -/* vim:set shiftwidth=4 softtabstop=4 expandtab: */ diff --git a/autodoc/source/ary/idl/i_reposypart.hxx b/autodoc/source/ary/idl/i_reposypart.hxx deleted file mode 100644 index 31c814836872..000000000000 --- a/autodoc/source/ary/idl/i_reposypart.hxx +++ /dev/null @@ -1,87 +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 ARY_IDL_I_REPOSYPART_HXX -#define ARY_IDL_I_REPOSYPART_HXX - - - -// USED SERVICES - // BASE CLASSES -#include <idl_internalgate.hxx> - // OTHER - - -namespace ary -{ -namespace idl -{ - class CeAdmin; - class TypeAdmin; - class NameLookup; -} -} - - - - - -namespace ary -{ -namespace idl -{ - - - -/** The idl part of the Autodoc repository. -*/ -class RepositoryPartition : public InternalGate -{ - public: - // LIFECYCLE - RepositoryPartition(); - ~RepositoryPartition(); - // INHERITED - // Interface Gate: - virtual void Calculate_AllSecondaryInformation( - const String & i_devman_reffilepath ); -// const ::autodoc::Options & -// i_options ); - virtual const CePilot & - Ces() const; - virtual const TypePilot & - Types() const; - virtual CePilot & Ces(); - virtual TypePilot & Types(); - - private: - // DATA - Dyn<CeAdmin> pCes; - Dyn<TypeAdmin> pTypes; - Dyn<NameLookup> pNamesDictionary; -}; - - - - -} // namespace idl -} // namespace ary -#endif - -/* vim:set shiftwidth=4 softtabstop=4 expandtab: */ diff --git a/autodoc/source/ary/idl/i_service.cxx b/autodoc/source/ary/idl/i_service.cxx deleted file mode 100644 index a95375ed06d4..000000000000 --- a/autodoc/source/ary/idl/i_service.cxx +++ /dev/null @@ -1,165 +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 . - */ - -#include <precomp.h> -#include <ary/idl/i_service.hxx> - - -// NOT FULLY DECLARED SERVICES -#include <cosv/tpl/processor.hxx> -#include <ary/idl/ik_service.hxx> -#include <ary/doc/d_oldidldocu.hxx> -#include <sci_impl.hxx> -#include "i2s_calculator.hxx" - - -namespace ary -{ -namespace idl -{ - -Service::Service( const String & i_sName, - Ce_id i_nOwner ) - : sName(i_sName), - nOwner(i_nOwner), - aIncludedServices(), - aSupportedInterfaces(), - aProperties() -{ -} - -Service::~Service() -{ - for ( RelationList::iterator it = aIncludedServices.begin(); - it != aIncludedServices.end(); - ++it ) - { - delete (*it).Info(); - } - - for ( RelationList::iterator it = aSupportedInterfaces.begin(); - it != aSupportedInterfaces.end(); - ++it ) - { - delete (*it).Info(); - } -} - -void -Service::Get_SupportedInterfaces( Dyn_StdConstIterator<CommentedRelation> & o_rResult ) const -{ - o_rResult = new SCI_Vector<CommentedRelation>(aSupportedInterfaces); -} - -void -Service::Get_IncludedServices( Dyn_StdConstIterator<CommentedRelation> & o_rResult ) const -{ - o_rResult = new SCI_Vector<CommentedRelation>(aIncludedServices); -} - -void -Service::do_Accept( csv::ProcessorIfc & io_processor ) const -{ - csv::CheckedCall(io_processor, *this); -} - -ClassId -Service::get_AryClass() const -{ - return class_id; -} - -const String & -Service::inq_LocalName() const -{ - return sName; -} - -Ce_id -Service::inq_NameRoom() const -{ - return nOwner; -} - -Ce_id -Service::inq_Owner() const -{ - return nOwner; -} - -E_SightLevel -Service::inq_SightLevel() const -{ - return sl_File; -} - - -namespace ifc_service -{ - -inline const Service & -service_cast( const CodeEntity & i_ce ) -{ - csv_assert( i_ce.AryClass() == Service::class_id ); - return static_cast< const Service& >(i_ce); -} - -void -attr::Get_IncludedServices( Dyn_StdConstIterator<CommentedRelation> & o_result, - const CodeEntity & i_ce ) -{ - o_result = new SCI_Vector<CommentedRelation>( service_cast(i_ce).aIncludedServices ); -} - -void -attr::Get_ExportedInterfaces( Dyn_StdConstIterator<CommentedRelation> & o_result, - const CodeEntity & i_ce ) -{ - o_result = new SCI_Vector<CommentedRelation>( service_cast(i_ce).aSupportedInterfaces ); -} - -void -attr::Get_Properties( Dyn_CeIterator & o_result, - const CodeEntity & i_ce ) -{ - o_result = new SCI_Vector<Ce_id>( service_cast(i_ce).aProperties ); -} - -void -xref::Get_IncludingServices( Dyn_CeIterator & o_result, - const CodeEntity & i_ce ) -{ - o_result = new SCI_Vector<Ce_id>(i_ce.Secondaries().List(service_2s_IncludingServices)); -} - -void -xref::Get_InstantiatingSingletons( Dyn_CeIterator & o_result, - const CodeEntity & i_ce ) -{ - o_result = new SCI_Vector<Ce_id>(i_ce.Secondaries().List(service_2s_InstantiatingSingletons)); -} - - -} // namespace ifc_service - - -} // namespace idl -} // namespace ary - -/* vim:set shiftwidth=4 softtabstop=4 expandtab: */ diff --git a/autodoc/source/ary/idl/i_singleton.cxx b/autodoc/source/ary/idl/i_singleton.cxx deleted file mode 100644 index 30489cc41d58..000000000000 --- a/autodoc/source/ary/idl/i_singleton.cxx +++ /dev/null @@ -1,106 +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 . - */ - -#include <precomp.h> -#include <ary/idl/i_singleton.hxx> - - -// NOT FULLY DECLARED SERVICES -#include <cosv/tpl/processor.hxx> -#include <ary/idl/ik_singleton.hxx> -#include <sci_impl.hxx> - - -namespace ary -{ -namespace idl -{ - -Singleton::Singleton( const String & i_sName, - Ce_id i_nOwner ) - : sName(i_sName), - nOwner(i_nOwner), - nService() -{ -} - -Singleton::~Singleton() -{ -} - -void -Singleton::do_Accept( csv::ProcessorIfc & io_processor ) const -{ - csv::CheckedCall(io_processor, *this); -} - -ClassId -Singleton::get_AryClass() const -{ - return class_id; -} - -const String & -Singleton::inq_LocalName() const -{ - return sName; -} - -Ce_id -Singleton::inq_NameRoom() const -{ - return nOwner; -} - -Ce_id -Singleton::inq_Owner() const -{ - return nOwner; -} - -E_SightLevel -Singleton::inq_SightLevel() const -{ - return sl_File; -} - - -namespace ifc_singleton -{ - -inline const Singleton & -singleton_cast( const CodeEntity & i_ce ) -{ - csv_assert( i_ce.AryClass() == Singleton::class_id ); - return static_cast< const Singleton& >(i_ce); -} - -Type_id -attr::AssociatedService( const CodeEntity & i_ce ) -{ - return singleton_cast(i_ce).nService; -} - -} // namespace ifc_singleton - - -} // namespace idl -} // namespace ary - -/* vim:set shiftwidth=4 softtabstop=4 expandtab: */ diff --git a/autodoc/source/ary/idl/i_siservice.cxx b/autodoc/source/ary/idl/i_siservice.cxx deleted file mode 100644 index eb922b78137e..000000000000 --- a/autodoc/source/ary/idl/i_siservice.cxx +++ /dev/null @@ -1,115 +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 . - */ - -#include <precomp.h> -#include <ary/idl/i_siservice.hxx> -#include <ary/idl/ik_siservice.hxx> - - -// NOT FULLY DECLARED SERVICES -#include <cosv/tpl/processor.hxx> -#include <sci_impl.hxx> - - -namespace ary -{ -namespace idl -{ - -SglIfcService::SglIfcService( const String & i_sName, - Ce_id i_nOwner, - Type_id i_nBaseInterface ) - : sName(i_sName), - nOwner(i_nOwner), - nBaseInterface(i_nBaseInterface), - aConstructors() -{ -} - -SglIfcService::~SglIfcService() -{ -} - -void -SglIfcService::do_Accept( csv::ProcessorIfc & io_processor ) const -{ - csv::CheckedCall(io_processor, *this); -} - -ClassId -SglIfcService::get_AryClass() const -{ - return class_id; -} - -const String & -SglIfcService::inq_LocalName() const -{ - return sName; -} - -Ce_id -SglIfcService::inq_NameRoom() const -{ - return nOwner; -} - -Ce_id -SglIfcService::inq_Owner() const -{ - return nOwner; -} - -E_SightLevel -SglIfcService::inq_SightLevel() const -{ - return sl_File; -} - - -namespace ifc_sglifcservice -{ - -inline const SglIfcService & -sglifcservice_cast( const CodeEntity & i_ce ) -{ - csv_assert( i_ce.AryClass() == SglIfcService::class_id ); - return static_cast< const SglIfcService& >(i_ce); -} - -Type_id -attr::BaseInterface( const CodeEntity & i_ce ) -{ - return sglifcservice_cast(i_ce).nBaseInterface; -} - -void -attr::Get_Constructors( Dyn_CeIterator & o_result, - const CodeEntity & i_ce ) -{ - o_result = new SCI_Vector<Ce_id>( sglifcservice_cast(i_ce).aConstructors ); -} - -} // namespace ifc_sglifcservice - - -} // namespace idl -} // namespace ary - -/* vim:set shiftwidth=4 softtabstop=4 expandtab: */ diff --git a/autodoc/source/ary/idl/i_sisingleton.cxx b/autodoc/source/ary/idl/i_sisingleton.cxx deleted file mode 100644 index 3338ceeb8f7c..000000000000 --- a/autodoc/source/ary/idl/i_sisingleton.cxx +++ /dev/null @@ -1,107 +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 . - */ - -#include <precomp.h> -#include <ary/idl/i_sisingleton.hxx> - - -// NOT FULLY DECLARED SERVICES -#include <cosv/tpl/processor.hxx> -#include <ary/idl/ik_sisingleton.hxx> - - - -namespace ary -{ -namespace idl -{ - -SglIfcSingleton::SglIfcSingleton( const String & i_sName, - Ce_id i_nOwner, - Type_id i_nBaseInterface ) - : sName(i_sName), - nOwner(i_nOwner), - nBaseInterface(i_nBaseInterface) -{ -} - -SglIfcSingleton::~SglIfcSingleton() -{ -} - -void -SglIfcSingleton::do_Accept( csv::ProcessorIfc & io_processor ) const -{ - csv::CheckedCall(io_processor, *this); -} - -ClassId -SglIfcSingleton::get_AryClass() const -{ - return class_id; -} - -const String & -SglIfcSingleton::inq_LocalName() const -{ - return sName; -} - -Ce_id -SglIfcSingleton::inq_NameRoom() const -{ - return nOwner; -} - -Ce_id -SglIfcSingleton::inq_Owner() const -{ - return nOwner; -} - -E_SightLevel -SglIfcSingleton::inq_SightLevel() const -{ - return sl_File; -} - -namespace ifc_sglifcsingleton -{ - -inline const SglIfcSingleton & -sglifcsingleton_cast( const CodeEntity & i_ce ) -{ - csv_assert( i_ce.AryClass() == SglIfcSingleton::class_id ); - return static_cast< const SglIfcSingleton& >(i_ce); -} - -Type_id -attr::BaseInterface( const CodeEntity & i_ce ) -{ - return sglifcsingleton_cast(i_ce).nBaseInterface; -} - - -} // namespace ifc_sglifcsingleton - - -} // namespace idl -} // namespace ary - -/* vim:set shiftwidth=4 softtabstop=4 expandtab: */ diff --git a/autodoc/source/ary/idl/i_struct.cxx b/autodoc/source/ary/idl/i_struct.cxx deleted file mode 100644 index 4ace19bfaea2..000000000000 --- a/autodoc/source/ary/idl/i_struct.cxx +++ /dev/null @@ -1,157 +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 . - */ - -#include <precomp.h> -#include <ary/idl/i_struct.hxx> -#include <ary/idl/ik_struct.hxx> - - -// NOT FULLY DECLARED SERVICES -#include <cosv/tpl/processor.hxx> -#include <sci_impl.hxx> -#include "i2s_calculator.hxx" - - -namespace ary -{ -namespace idl -{ - -Struct::Struct( const String & i_sName, - Ce_id i_nOwner, - Type_id i_nBase, - const String & i_sTemplateParameter, - Type_id i_nTemplateParameterType ) - : sName(i_sName), - nOwner(i_nOwner), - nBase(i_nBase), - sTemplateParameter(i_sTemplateParameter), - nTemplateParameterType(i_nTemplateParameterType), - aElements() -{ -} - -Struct::~Struct() -{ -} - -void -Struct::do_Accept( csv::ProcessorIfc & io_processor ) const -{ - csv::CheckedCall(io_processor, *this); -} - -ClassId -Struct::get_AryClass() const -{ - return class_id; -} - -const String & -Struct::inq_LocalName() const -{ - return sName; -} - -Ce_id -Struct::inq_NameRoom() const -{ - return nOwner; -} - -Ce_id -Struct::inq_Owner() const -{ - return nOwner; -} - -E_SightLevel -Struct::inq_SightLevel() const -{ - return sl_File; -} - - -namespace ifc_struct -{ - -inline const Struct & -struct_cast( const CodeEntity & i_ce ) -{ - csv_assert( i_ce.AryClass() == Struct::class_id ); - return static_cast< const Struct& >(i_ce); -} - -Type_id -attr::Base( const CodeEntity & i_ce ) -{ - return struct_cast(i_ce).nBase; -} - -void -attr::Get_Elements( Dyn_CeIterator & o_result, - const CodeEntity & i_ce ) -{ - o_result = new SCI_Vector<Ce_id>( struct_cast(i_ce).aElements ); -} - - -void -xref::Get_Derivations( Dyn_CeIterator & o_result, - const CodeEntity & i_ce ) -{ - o_result = new SCI_Vector<Ce_id>(i_ce.Secondaries().List(struct_2s_Derivations)); -} - -void -xref::Get_SynonymTypedefs( Dyn_CeIterator & o_result, - const CodeEntity & i_ce ) -{ - o_result = new SCI_Vector<Ce_id>(i_ce.Secondaries().List(struct_2s_SynonymTypedefs)); -} - -void -xref::Get_AsReturns( Dyn_CeIterator & o_result, - const CodeEntity & i_ce ) -{ - o_result = new SCI_Vector<Ce_id>(i_ce.Secondaries().List(struct_2s_AsReturns)); -} - -void -xref::Get_AsParameters( Dyn_CeIterator & o_result, - const CodeEntity & i_ce ) -{ - o_result = new SCI_Vector<Ce_id>(i_ce.Secondaries().List(struct_2s_AsParameters)); -} - -void -xref::Get_AsDataTypes( Dyn_CeIterator & o_result, - const CodeEntity & i_ce ) -{ - o_result = new SCI_Vector<Ce_id>(i_ce.Secondaries().List(struct_2s_AsDataTypes)); -} - -} // namespace ifc_struct - - - -} // namespace idl -} // namespace ary - -/* vim:set shiftwidth=4 softtabstop=4 expandtab: */ diff --git a/autodoc/source/ary/idl/i_structelem.cxx b/autodoc/source/ary/idl/i_structelem.cxx deleted file mode 100644 index f02e42e12c00..000000000000 --- a/autodoc/source/ary/idl/i_structelem.cxx +++ /dev/null @@ -1,111 +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 . - */ - -#include <precomp.h> -#include <ary/idl/i_structelem.hxx> -#include <ary/idl/ik_structelem.hxx> - - -// NOT FULLY DECLARED SERVICES -#include <cosv/tpl/processor.hxx> -#include <sci_impl.hxx> - - -namespace ary -{ -namespace idl -{ - - -StructElement::StructElement( const String & i_sName, - Ce_id i_nOwner, - Ce_id i_nNameRoom, - Type_id i_nType ) - : sName(i_sName), - nOwner(i_nOwner), - nNameRoom(i_nNameRoom), - nType(i_nType) -{ -} - -StructElement::~StructElement() -{ -} - -void -StructElement::do_Accept( csv::ProcessorIfc & io_processor ) const -{ - csv::CheckedCall(io_processor, *this); -} - -ClassId -StructElement::get_AryClass() const -{ - return class_id; -} - -const String & -StructElement::inq_LocalName() const -{ - return sName; -} - -Ce_id -StructElement::inq_NameRoom() const -{ - return nNameRoom; -} - -Ce_id -StructElement::inq_Owner() const -{ - return nOwner; -} - -E_SightLevel -StructElement::inq_SightLevel() const -{ - return sl_Member; -} - - -namespace ifc_structelement -{ - -inline const StructElement & -selem_cast( const CodeEntity & i_ce ) -{ - csv_assert( i_ce.AryClass() == StructElement::class_id ); - return static_cast< const StructElement& >(i_ce); -} - -Type_id -attr::Type( const CodeEntity & i_ce ) -{ - return selem_cast(i_ce).nType; -} - -} // namespace ifc_structelement - - - -} // namespace idl -} // namespace ary - -/* vim:set shiftwidth=4 softtabstop=4 expandtab: */ diff --git a/autodoc/source/ary/idl/i_traits.cxx b/autodoc/source/ary/idl/i_traits.cxx deleted file mode 100644 index 6944985259aa..000000000000 --- a/autodoc/source/ary/idl/i_traits.cxx +++ /dev/null @@ -1,66 +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 . - */ - -#include <precomp.h> -#include <ary/idl/i_traits.hxx> - - -// NOT FULLY DEFINED SERVICES -#include <ary/namesort.hxx> -#include "is_ce.hxx" - - - -namespace ary -{ -namespace idl -{ - - - -//******************** Ce_Traits ********************// -Ce_Traits::entity_base_type & -Ce_Traits::EntityOf_(id_type i_id) -{ - csv_assert(i_id.IsValid()); - return Ce_Storage::Instance_()[i_id]; -} - -//******************** Ce_Compare ********************// -const Ce_Compare::key_type & -Ce_Compare::KeyOf_(const entity_base_type & i_entity) -{ - return i_entity.LocalName(); -} - -bool -Ce_Compare::Lesser_( const key_type & i_1, - const key_type & i_2 ) -{ - static ::ary::LesserName less_; - return less_(i_1,i_2); -} - - - - -} // namespace idl -} // namespace ary - -/* vim:set shiftwidth=4 softtabstop=4 expandtab: */ diff --git a/autodoc/source/ary/idl/i_typedef.cxx b/autodoc/source/ary/idl/i_typedef.cxx deleted file mode 100644 index 9e79168d7f12..000000000000 --- a/autodoc/source/ary/idl/i_typedef.cxx +++ /dev/null @@ -1,139 +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 . - */ - -#include <precomp.h> -#include <ary/idl/i_typedef.hxx> -#include <ary/idl/ik_typedef.hxx> - - -// NOT FULLY DECLARED SERVICES -#include <cosv/tpl/processor.hxx> -#include <sci_impl.hxx> -#include "i2s_calculator.hxx" - - -namespace ary -{ -namespace idl -{ - - -Typedef::Typedef( const String & i_sName, - Ce_id i_nOwner, - Type_id i_nDefiningType ) - : sName(i_sName), - nOwner(i_nOwner), - nDefiningType(i_nDefiningType) -{ -} - -Typedef::~Typedef() -{ -} - -void -Typedef::do_Accept( csv::ProcessorIfc & io_processor ) const -{ - csv::CheckedCall(io_processor, *this); -} - -ClassId -Typedef::get_AryClass() const -{ - return class_id; -} - -const String & -Typedef::inq_LocalName() const -{ - return sName; -} - -Ce_id -Typedef::inq_NameRoom() const -{ - return nOwner; -} - -Ce_id -Typedef::inq_Owner() const -{ - return nOwner; -} - -E_SightLevel -Typedef::inq_SightLevel() const -{ - return sl_File; -} - - -namespace ifc_typedef -{ - -inline const Typedef & -typedef_cast( const CodeEntity & i_ce ) -{ - csv_assert( i_ce.AryClass() == Typedef::class_id ); - return static_cast< const Typedef& >(i_ce); -} - -Type_id -attr::DefiningType( const CodeEntity & i_ce ) -{ - return typedef_cast(i_ce).nDefiningType; -} - - -void -xref::Get_SynonymTypedefs( Dyn_CeIterator & o_result, - const CodeEntity & i_ce ) -{ - o_result = new SCI_Vector<Ce_id>(i_ce.Secondaries().List(typedef_2s_SynonymTypedefs)); -} - -void -xref::Get_AsReturns( Dyn_CeIterator & o_result, - const CodeEntity & i_ce ) -{ - o_result = new SCI_Vector<Ce_id>(i_ce.Secondaries().List(typedef_2s_AsReturns)); -} - -void -xref::Get_AsParameters( Dyn_CeIterator & o_result, - const CodeEntity & i_ce ) -{ - o_result = new SCI_Vector<Ce_id>(i_ce.Secondaries().List(typedef_2s_AsParameters)); -} - -void -xref::Get_AsDataTypes( Dyn_CeIterator & o_result, - const CodeEntity & i_ce ) -{ - o_result = new SCI_Vector<Ce_id>(i_ce.Secondaries().List(typedef_2s_AsDataTypes)); -} - -} // namespace ifc_typedef - - - -} // namespace idl -} // namespace ary - -/* vim:set shiftwidth=4 softtabstop=4 expandtab: */ diff --git a/autodoc/source/ary/idl/ia_ce.cxx b/autodoc/source/ary/idl/ia_ce.cxx deleted file mode 100644 index 248b01bbb987..000000000000 --- a/autodoc/source/ary/idl/ia_ce.cxx +++ /dev/null @@ -1,575 +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 . - */ - -#include <precomp.h> -#include "ia_ce.hxx" - - -// NOT FULLY DEFINED SERVICES -#include <algorithm> -#include <cosv/tpl/tpltools.hxx> -#include <ary/idl/i_attribute.hxx> -#include <ary/idl/i_constant.hxx> -#include <ary/idl/i_constgroup.hxx> -#include <ary/idl/i_enum.hxx> -#include <ary/idl/i_enumvalue.hxx> -#include <ary/idl/i_exception.hxx> -#include <ary/idl/i_function.hxx> -#include <ary/idl/i_interface.hxx> -#include <ary/idl/i_module.hxx> -#include <ary/idl/i_namelookup.hxx> -#include <ary/idl/i_property.hxx> -#include <ary/idl/i_service.hxx> -#include <ary/idl/i_singleton.hxx> -#include <ary/idl/i_siservice.hxx> -#include <ary/idl/i_sisingleton.hxx> -#include <ary/idl/i_struct.hxx> -#include <ary/idl/i_structelem.hxx> -#include <ary/idl/i_traits.hxx> -#include <ary/idl/i_typedef.hxx> -#include <idsort.hxx> -#include "ia_type.hxx" -#include "is_ce.hxx" -#include "it_tplparam.hxx" - - - - -namespace ary -{ -namespace idl -{ - -inline Module & -CeAdmin::lhf_Access_Module( Ce_id i_nId ) - { return ary_cast<Module>(Storage()[i_nId]); } - -inline void -CeAdmin::lhf_Put2Storage_and_AssignId( CodeEntity & pass_io_rCe ) - { // This also assigns an ID to pass_io_rCe: - Storage().Store_Entity(pass_io_rCe); - my_NameDictionary().Add_Name( pass_io_rCe.LocalName(), - pass_io_rCe.CeId(), - pass_io_rCe.AryClass(), - pass_io_rCe.Owner() ); - } - -inline void -CeAdmin::lhf_Store_NewEntity( DYN CodeEntity & pass_io_rCe, - Module & i_rOwner ) -{ - lhf_Put2Storage_and_AssignId(pass_io_rCe); - i_rOwner.Add_Name(pass_io_rCe.LocalName(), pass_io_rCe.CeId()); -} - -inline void -CeAdmin::lhf_Store_NewEntity( DYN CodeEntity & pass_io_rCe, - Ce_id i_nOwnerModule ) -{ - lhf_Store_NewEntity(pass_io_rCe, lhf_Access_Module(i_nOwnerModule)); -} - - - -CeAdmin::CeAdmin( NameLookup & io_rNameDictionary, - TypeAdmin & io_rTypePilot ) - : pStorage(new Ce_Storage), - pGlobalNamespace(0), - pNameDictionary(&io_rNameDictionary), - pTypePilot(&io_rTypePilot) -{ - Storage().Set_Reserved( - predefined::ce_GlobalNamespace, - *new Module ); - pGlobalNamespace = &lhf_Access_Module(Ce_id(predefined::ce_GlobalNamespace)); -} - -CeAdmin::~CeAdmin() -{ -} - - - -Module & -CeAdmin::CheckIn_Module( Ce_id i_nParentId, - const String & i_sName ) -{ - Module & rOwner = lhf_Access_Module(i_nParentId); - Ce_id nId = rOwner.Search_Name(i_sName); - if (nId.IsValid()) - { - return lhf_Access_Module(nId); - } - - Module & ret = *new Module( i_sName, - rOwner ); - lhf_Store_NewEntity(ret, rOwner); - return ret; -} - -Service & -CeAdmin::Store_Service( Ce_id i_nOwner, - const String & i_sName ) -{ - Service & ret = *new Service( i_sName, - i_nOwner ); - lhf_Store_NewEntity(ret, i_nOwner); - return ret; -} - -SglIfcService & -CeAdmin::Store_SglIfcService( Ce_id i_nOwner, - const String & i_sName, - Type_id i_nBaseInterface ) -{ - SglIfcService & - ret = *new SglIfcService( i_sName, - i_nOwner, - i_nBaseInterface ); - lhf_Store_NewEntity(ret, i_nOwner); - return ret; -} - -Interface & -CeAdmin::Store_Interface( Ce_id i_nOwner, - const String & i_sName, - Type_id i_nBase ) -{ - Interface & ret = *new Interface( i_sName, - i_nOwner ); - lhf_Store_NewEntity(ret, i_nOwner); - if (i_nBase.IsValid()) - ret.Add_Base(i_nBase, 0); - return ret; -} - -Struct & -CeAdmin::Store_Struct( Ce_id i_nOwner, - const String & i_sName, - Type_id i_nBase, - const String & i_sTemplateParam ) -{ - if (NOT i_sTemplateParam.empty()) - { - return lhf_Store_TplStruct( i_nOwner, - i_sName, - i_nBase, - i_sTemplateParam ); - } - - Struct & ret = *new Struct( i_sName, - i_nOwner, - i_nBase, - String::Null_(), - Type_id::Null_() ); - lhf_Store_NewEntity(ret, i_nOwner); - - return ret; -} - -Exception & -CeAdmin::Store_Exception( Ce_id i_nOwner, - const String & i_sName, - Type_id i_nBase ) -{ - Exception & ret = *new Exception( i_sName, - i_nOwner, - i_nBase ); - lhf_Store_NewEntity(ret, i_nOwner); - return ret; -} - -Enum & -CeAdmin::Store_Enum( Ce_id i_nOwner, - const String & i_sName ) -{ - Enum & ret = *new Enum( i_sName, - i_nOwner ); - lhf_Store_NewEntity(ret, i_nOwner); - return ret; -} - -Typedef & -CeAdmin::Store_Typedef( Ce_id i_nOwner, - const String & i_sName, - Type_id i_nDefiningType ) -{ - Typedef & ret = *new Typedef( i_sName, - i_nOwner, - i_nDefiningType ); - lhf_Store_NewEntity(ret, i_nOwner); - return ret; -} - - -ConstantsGroup & -CeAdmin::Store_ConstantsGroup( Ce_id i_nOwner, - const String & i_sName ) -{ - ConstantsGroup & ret = *new ConstantsGroup( i_sName, - i_nOwner ); - lhf_Store_NewEntity(ret, i_nOwner); - return ret; -} - -Singleton & -CeAdmin::Store_Singleton( Ce_id i_nOwner, - const String & i_sName ) -{ - Singleton & ret = *new Singleton( i_sName, - i_nOwner ); - lhf_Store_NewEntity(ret, i_nOwner); - return ret; -} - -SglIfcSingleton & -CeAdmin::Store_SglIfcSingleton( Ce_id i_nOwner, - const String & i_sName, - Type_id i_nBaseInterface ) -{ - SglIfcSingleton & - ret = *new SglIfcSingleton( i_sName, - i_nOwner, - i_nBaseInterface ); - lhf_Store_NewEntity(ret, i_nOwner); - return ret; -} - -Constant & -CeAdmin::Store_Constant( Ce_id i_nOwner, - const String & i_sName, - Type_id i_nType, - const String & i_sValue ) -{ - ConstantsGroup & - rOwner = ary_cast<ConstantsGroup>(Storage()[i_nOwner]); - Constant & ret = *new Constant( i_sName, - i_nOwner, - rOwner.NameRoom(), - i_nType, - i_sValue ); - lhf_Put2Storage_and_AssignId(ret); - rOwner.Add_Constant(ret.CeId()); - return ret; -} - -Property & -CeAdmin::Store_Property( Ce_id i_nOwner, - const String & i_sName, - Type_id i_nType, - Property::Stereotypes i_stereotypes ) -{ - Service & - rOwner = ary_cast<Service>(Storage()[i_nOwner]); - Property & ret = *new Property( i_sName, - i_nOwner, - rOwner.NameRoom(), - i_nType, - i_stereotypes ); - lhf_Put2Storage_and_AssignId(ret); - rOwner.Add_Property(ret.CeId()); - return ret; -} - -Function & -CeAdmin::Store_Function( Ce_id i_nOwner, - const String & i_sName, - Type_id i_nReturnType, - bool i_bOneWay ) -{ - Interface & - rOwner = ary_cast<Interface>(Storage()[i_nOwner]); - Function & ret = *new Function( i_sName, - i_nOwner, - rOwner.NameRoom(), - i_nReturnType, - i_bOneWay); - lhf_Put2Storage_and_AssignId(ret); - rOwner.Add_Function(ret.CeId()); - return ret; -} - -Function & -CeAdmin::Store_ServiceConstructor( Ce_id i_nOwner, - const String & i_sName ) -{ - SglIfcService & - rOwner = ary_cast<SglIfcService>(Storage()[i_nOwner]); - Function & ret = *new Function( i_sName, - i_nOwner, - rOwner.NameRoom() ); - lhf_Put2Storage_and_AssignId(ret); - rOwner.Add_Constructor(ret.CeId()); - return ret; -} - -StructElement & -CeAdmin::Store_StructMember( Ce_id i_nOwner, - const String & i_sName, - Type_id i_nType ) -{ - Struct & - rOwner = ary_cast<Struct>(Storage()[i_nOwner]); - StructElement & ret = *new StructElement( i_sName, - i_nOwner, - rOwner.NameRoom(), - i_nType ); - lhf_Put2Storage_and_AssignId(ret); - rOwner.Add_Member(ret.CeId()); - return ret; -} - -StructElement & -CeAdmin::Store_ExceptionMember( Ce_id i_nOwner, - const String & i_sName, - Type_id i_nType ) -{ - Exception & - rOwner = ary_cast<Exception>(Storage()[i_nOwner]); - StructElement & ret = *new StructElement( i_sName, - i_nOwner, - rOwner.NameRoom(), - i_nType ); - lhf_Put2Storage_and_AssignId(ret); - rOwner.Add_Member(ret.CeId()); - return ret; -} - -EnumValue & -CeAdmin::Store_EnumValue( Ce_id i_nOwner, - const String & i_sName, - const String & i_sValue ) -{ - Enum & - rOwner = ary_cast<Enum>(Storage()[i_nOwner]); - EnumValue & ret = *new EnumValue( i_sName, - i_nOwner, - rOwner.NameRoom(), - i_sValue ); - lhf_Put2Storage_and_AssignId(ret); - rOwner.Add_Value(ret.CeId()); - return ret; -} - -Attribute & -CeAdmin::Store_Attribute( Ce_id i_nOwner, - const String & i_sName, - Type_id i_nType, - bool i_bReadOnly, - bool i_bBound ) -{ - Interface & - rOwner = ary_cast<Interface>(Storage()[i_nOwner]); - - Attribute & ret = *new Attribute ( i_sName, - i_nOwner, - rOwner.NameRoom(), - i_nType, - i_bReadOnly, - i_bBound ); - lhf_Put2Storage_and_AssignId(ret); - rOwner.Add_Attribute(ret.CeId()); - return ret; -} - -const Module & -CeAdmin::GlobalNamespace() const -{ - csv_assert(pGlobalNamespace); - return *pGlobalNamespace; -} - -const CodeEntity & -CeAdmin::Find_Ce( Ce_id i_nId ) const -{ - return Storage()[i_nId]; - -} - -const Module & -CeAdmin::Find_Module( Ce_id i_nId ) const -{ - return ary_cast<Module>(Storage()[i_nId]); -} - -const Module * -CeAdmin::Search_Module( Ce_id i_nId ) const -{ - if (NOT i_nId.IsValid()) - return 0; - return ary_cast<Module>( & Storage()[i_nId] ); -} - -const Function & -CeAdmin::Find_Function( Ce_id i_nId ) const -{ - return ary_cast<Function>(Storage()[i_nId]); -} - -const Property & -CeAdmin::Find_Property( Ce_id i_nId ) const -{ - return ary_cast<Property>(Storage()[i_nId]); -} - -const EnumValue & -CeAdmin::Find_EnumValue( Ce_id i_nId ) const -{ - return ary_cast<EnumValue>(Storage()[i_nId]); -} - -const Constant & -CeAdmin::Find_Constant( Ce_id i_nId ) const -{ - return ary_cast<Constant>(Storage()[i_nId]); -} - -const StructElement & -CeAdmin::Find_StructElement( Ce_id i_nId ) const -{ - return ary_cast<StructElement>(Storage()[i_nId]); -} - -void -CeAdmin::Get_Text( StringVector & o_module, - String & o_ce, - String & o_member, - const CodeEntity & i_ce ) const -{ - const CodeEntity * pCe = &i_ce; - csv::erase_container(o_module); - o_ce.clear(); - o_member.clear(); - - switch ( pCe->SightLevel() ) - { - // Here are intentionally no breaks! - case sl_Member: - if ( is_type<Function>(*pCe) ) - o_member = StreamLock(200)() - << pCe->LocalName() - << "()" - << c_str; - else - o_member = pCe->LocalName(); - pCe = & Storage()[pCe->Owner()]; - case sl_File: - o_ce = pCe->LocalName(); - pCe = & Storage()[pCe->NameRoom()]; - case sl_Module: - get_ModuleText(o_module,*pCe); - break; - default: - csv_assert(false); - } // end switch -} - -const NameLookup & -CeAdmin::NameDictionary() const -{ - return *pNameDictionary; -} - - -void -CeAdmin::Get_AlphabeticalIndex( std::vector<Ce_id> & o_rResult, - alphabetical_index::E_Letter i_cLetter ) const -{ - const int C_nLowerUpperDiff = 'a'-'A'; - - // Establishing filter: - UINT8 filter[256]; - - UINT8 nLetter = static_cast<UINT8>(i_cLetter); - memset(filter, 0, 256); - filter[nLetter] = 1; - if ( i_cLetter != alphabetical_index::non_alpha ) - filter[nLetter - C_nLowerUpperDiff] = 1; - - // Gather entities which start with i_cLetter: - o_rResult.reserve(1000); - idl::Ce_Storage::c_iter - itEnd = Storage().End(); - for ( idl::Ce_Storage::c_iter it = Storage().BeginUnreserved(); - it != itEnd; - ++it ) - { - if ( filter[ static_cast<UINT8>(*(*it).LocalName().c_str()) ] == 1 ) - o_rResult.push_back( (*it).CeId() ); - } - - std::sort( o_rResult.begin(), - o_rResult.end(), - IdSorter<Ce_Compare>() ); -} - - -Module & -CeAdmin::GlobalNamespace() -{ - csv_assert(pGlobalNamespace); - return *pGlobalNamespace; -} - -CodeEntity & -CeAdmin::Find_Ce( Ce_id i_nId ) -{ - return Storage()[i_nId]; -} - -void -CeAdmin::get_ModuleText( StringVector & o_module, - const CodeEntity & i_ce ) const -{ - if (i_ce.NameRoom().IsValid()) - { - const CodeEntity & - rParent = Storage()[i_ce.NameRoom()]; - get_ModuleText(o_module, rParent); - o_module.push_back(i_ce.LocalName()); - } -} - -Struct & -CeAdmin::lhf_Store_TplStruct( Ce_id i_nOwner, - const String & i_sName, - Type_id i_nBase, - const String & i_sTemplateParam ) -{ - csv_assert(NOT i_sTemplateParam.empty()); - - TemplateParamType & - rTpt = pTypePilot->Store_TemplateParamType(i_sTemplateParam); - - Struct & ret = *new Struct( i_sName, - i_nOwner, - i_nBase, - i_sTemplateParam, - rTpt.TypeId() ); - lhf_Store_NewEntity(ret, i_nOwner); - rTpt.Set_StructId(ret.CeId()); - - return ret; -} - - -} // namespace idl -} // namespace ary - -/* vim:set shiftwidth=4 softtabstop=4 expandtab: */ diff --git a/autodoc/source/ary/idl/ia_ce.hxx b/autodoc/source/ary/idl/ia_ce.hxx deleted file mode 100644 index 9949f5c26397..000000000000 --- a/autodoc/source/ary/idl/ia_ce.hxx +++ /dev/null @@ -1,247 +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 ARY_IDL_IA_CE_HXX -#define ARY_IDL_IA_CE_HXX - - -// USED SERVICES - // BASE CLASSES -#include <ary/idl/ip_ce.hxx> - // COMPONENTS - // PARAMETERS - - -namespace ary -{ -namespace idl -{ - -class Ce_Storage; -class TypeAdmin; - - -/** @resp - Implements ::ary::idl::CePilot. Provides the access logic for all - IDL code entities. - - @collab Ce_Storage - @collab TypeAdmin - - @see CodeEntity -*/ -class CeAdmin : public CePilot -{ - public: - // LIFECYCLE - CeAdmin( - NameLookup & io_rNameDictionary, - TypeAdmin & io_rTypePilot ); - virtual ~CeAdmin(); - - // OPERATIONS - - // INQUIRY - const Ce_Storage & Storage() const; - - // ACCESS - Ce_Storage & Storage(); - - // INHERITED - // Interface ::ary::idl::CePilot: - virtual Module & CheckIn_Module( - Ce_id i_nParentId, - const String & i_sName ); - virtual Service & Store_Service( - Ce_id i_nOwner, - const String & i_sName ); - virtual SglIfcService & - Store_SglIfcService( - Ce_id i_nOwner, - const String & i_sName, - Type_id i_nBaseInterface ); - virtual Interface & Store_Interface( - Ce_id i_nOwner, - const String & i_sName, - Type_id i_nBase ); - virtual Struct & Store_Struct( - Ce_id i_nOwner, - const String & i_sName, - Type_id i_nBase, - const String & i_sTemplateParam ); - virtual Exception & Store_Exception( - Ce_id i_nOwner, - const String & i_sName, - Type_id i_nBase ); - virtual Enum & Store_Enum( - Ce_id i_nOwner, - const String & i_sName ); - virtual Typedef & Store_Typedef( - Ce_id i_nOwner, - const String & i_sName, - Type_id i_nDefiningType ); - virtual ConstantsGroup & - Store_ConstantsGroup( - Ce_id i_nOwner, - const String & i_sName ); - virtual Singleton & Store_Singleton( - Ce_id i_nOwner, - const String & i_sName ); - virtual SglIfcSingleton & - Store_SglIfcSingleton( - Ce_id i_nOwner, - const String & i_sName, - Type_id i_nBaseInterface ); - - virtual Constant & Store_Constant( - Ce_id i_nOwner, - const String & i_sName, - Type_id i_nType, - const String & i_sValue ); - virtual Property & Store_Property( - Ce_id i_nOwner, - const String & i_sName, - Type_id i_nType, - Property::Stereotypes - i_stereotypes ); - virtual Function & Store_Function( - Ce_id i_nOwner, - const String & i_sName, - Type_id i_nReturnType, - bool i_bOneWay ); - virtual Function & Store_ServiceConstructor( - Ce_id i_nOwner, - const String & i_sName ); - virtual StructElement & - Store_StructMember( - Ce_id i_nOwner, - const String & i_sName, - Type_id i_nType ); - virtual StructElement & - Store_ExceptionMember( - Ce_id i_nOwner, - const String & i_sName, - Type_id i_nType ); - virtual EnumValue & Store_EnumValue( - Ce_id i_nOwner, - const String & i_sName, - const String & i_sValue ); - virtual Attribute & Store_Attribute( - Ce_id i_nOwner, - const String & i_sName, - Type_id i_nType, - bool i_bReadOnly, - bool i_bBound ); - - virtual const Module & - GlobalNamespace() const; - virtual const CodeEntity & - Find_Ce( - Ce_id i_nId ) const; - virtual const Module & - Find_Module( - Ce_id i_nId ) const; - virtual const Module * - Search_Module( - Ce_id i_nId ) const; - virtual const Function & - Find_Function( - Ce_id i_nId ) const; - virtual const Property & - Find_Property( - Ce_id i_nId ) const; - virtual const EnumValue & - Find_EnumValue( - Ce_id i_nId ) const; - virtual const Constant & - Find_Constant( - Ce_id i_nId ) const; - virtual const StructElement & - Find_StructElement( - Ce_id i_nId ) const; - virtual void Get_Text( - StringVector & o_module, - String & o_ce, - String & o_member, - const CodeEntity & i_ce ) const; - virtual const NameLookup & - NameDictionary() const; - virtual void Get_AlphabeticalIndex( - std::vector<Ce_id> & - o_rResult, - alphabetical_index::E_Letter - i_cLetter) const; - // ACCESS - virtual Module & GlobalNamespace(); - virtual CodeEntity & - Find_Ce( - Ce_id i_nId ); - private: - // Locals - Module & lhf_Access_Module( - Ce_id i_nId ); - void lhf_Put2Storage_and_AssignId( - CodeEntity & pass_io_rCe ); - void lhf_Store_NewEntity( - DYN CodeEntity & pass_io_rCe, - Module & i_rOwner ); - void lhf_Store_NewEntity( - DYN CodeEntity & pass_io_rCe, - Ce_id i_nOwnerModule ); - void get_ModuleText( - StringVector & o_module, - const CodeEntity & i_ce ) const; - Struct & lhf_Store_TplStruct( - Ce_id i_nOwner, - const String & i_sName, - Type_id i_nBase, - const String & i_sTemplateParam ); - - const Ce_Storage & my_Storage() const; - Ce_Storage & my_Storage(); - NameLookup & my_NameDictionary() { return *pNameDictionary; } - - // DATA - Dyn<Ce_Storage> pStorage; /// @inv pStorage != 0; - Module * pGlobalNamespace; - NameLookup * pNameDictionary; - TypeAdmin * pTypePilot; -}; - - -// IMPLEMENTATION -inline const Ce_Storage & -CeAdmin::Storage() const -{ - return *pStorage; -} - -inline Ce_Storage & -CeAdmin::Storage() -{ - return *pStorage; -} - - - -} // namespace idl -} // namespace ary -#endif - -/* vim:set shiftwidth=4 softtabstop=4 expandtab: */ diff --git a/autodoc/source/ary/idl/ia_type.cxx b/autodoc/source/ary/idl/ia_type.cxx deleted file mode 100644 index 82bdea1b1fdb..000000000000 --- a/autodoc/source/ary/idl/ia_type.cxx +++ /dev/null @@ -1,353 +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 . - */ - -#include <precomp.h> -#include "ia_type.hxx" - - -// NOT FULLY DEFINED SERVICES -#include <ary/qualiname.hxx> -#include <ary/idl/i_module.hxx> -#include <ary/idl/i_type.hxx> -#include <ary/idl/ip_ce.hxx> -#include "ia_ce.hxx" -#include "is_type.hxx" -#include "it_builtin.hxx" -#include "it_ce.hxx" -#include "it_explicit.hxx" -#include "it_sequence.hxx" -#include "it_tplparam.hxx" -#include "it_xnameroom.hxx" - - - -namespace ary -{ -namespace idl -{ - -String MakeTemplateName( - const String & i_localName ); - - - -inline CeAdmin & -TypeAdmin::my_Ces() const - { return *pCes; } - -inline void -TypeAdmin::lhf_Put2Storage_and_AssignId( DYN Type & pass_io_rType ) - { // This also assigns an ID to pass_io_rType: - Storage().Store_Entity(pass_io_rType); } - -inline Type_id -TypeAdmin::lhf_findBuiltInType( const String & i_sName ) - { return ary_cast<ExplicitNameRoom>(Storage()[nXNameRoom_Root]) - .Search_Name(i_sName); } - -inline const ExplicitNameRoom & -TypeAdmin::find_ExplicitNameRoom( Type_id i_nType ) const -{ - return ary_cast<ExplicitNameRoom>(Storage()[i_nType]); -} - -inline ExplicitNameRoom & -TypeAdmin::find_ExplicitNameRoom( Type_id i_nType ) -{ - return ary_cast<ExplicitNameRoom>(Storage()[i_nType]); -} - -ExplicitNameRoom & -TypeAdmin::lhf_CheckIn_XNameRoom( const QualifiedName & i_rName, - Ce_id i_nModuleOfOccurrence ) -{ - Type_id nRoot = i_rName.IsAbsolute() - ? Type_id( predefined::type_GlobalXNameRoom ) - : lhf_Get_NameRoomRoot_forModuleofOccurrence( i_nModuleOfOccurrence ).TypeId(); - - if ( i_rName.NamespaceDepth() == 0 ) - return find_ExplicitNameRoom(nRoot); - - QualifiedName::namespace_iterator it = i_rName.first_namespace(); - ExplicitNameRoom * - ret = & find_ExplicitNameRoom(nRoot); - for ( ; it != i_rName.end_namespace(); ++it ) - { - Type_id - found = ret->Search_Name(*it); - if (found.IsValid()) - { - ret = & find_ExplicitNameRoom(found); - } - else - { - ExplicitNameRoom & - rNew = *new ExplicitNameRoom(*it, *ret); - lhf_Put2Storage_and_AssignId(rNew); - ret->Add_Name( rNew.Name(), rNew.TypeId() ); - ret = &rNew; - } - - } // end for - return *ret; -} - -Type_id -TypeAdmin::lhf_CheckIn_TypeName( const String & i_sLocalName, - ExplicitNameRoom & io_rXNameRoom, - Ce_id i_nModuleOfOccurrence, - const std::vector<Type_id> * i_templateParameters ) -{ - String sSearchLocalName( i_sLocalName ); - if ( i_templateParameters != 0 - ? (!i_templateParameters->empty()) - : false ) - { - sSearchLocalName = MakeTemplateName(i_sLocalName); - } - - Type_id - ret = io_rXNameRoom.Search_Name(sSearchLocalName); - if (NOT ret.IsValid()) - { - DYN Type & - rNewType = *new ExplicitType( i_sLocalName, - io_rXNameRoom.TypeId(), - i_nModuleOfOccurrence, - i_templateParameters ); - lhf_Put2Storage_and_AssignId(rNewType); - ret = rNewType.TypeId(); - io_rXNameRoom.Add_Name( sSearchLocalName, ret ); - } - return ret; -} - -Type_id -TypeAdmin::lhf_CheckIn_Sequence(Type_id i_nType) -{ - Type_id - ret = Storage().Search_SequenceOf(i_nType); - - if (NOT ret.IsValid()) - { - DYN Type & - rNewSeq = *new Sequence(i_nType); - lhf_Put2Storage_and_AssignId(rNewSeq); - ret = rNewSeq.Id(); - Storage().Add_Sequence(i_nType, ret); - } - return ret; -} - -void -TypeAdmin::lhf_CheckIn_BuiltInType( const char * i_sName, - Rid i_nId ) -{ - DYN BuiltInType & - rNewType = *new BuiltInType(i_sName); - Storage().Set_Reserved(i_nId, rNewType); - - // Put them into both roots, to catch the syntactically correct - // (though unlikely) ::Any, ::long etc. - Type_id - nId(i_nId); - find_ExplicitNameRoom(nXNameRoom_Root).Add_Name(i_sName, nId); - find_ExplicitNameRoom(nXNameRoom_Global).Add_Name(i_sName, nId); -} - -ExplicitNameRoom & -TypeAdmin::lhf_Get_NameRoomRoot_forModuleofOccurrence( Ce_id i_nModuleOfOccurrence ) -{ - const Type_id * - pFound = csv::find_in_map( aMap_ModuleOfOccurrence2NameRoomRoot, - i_nModuleOfOccurrence ); - if (pFound != 0) - return find_ExplicitNameRoom(*pFound); - - ExplicitNameRoom & - ret = *new ExplicitNameRoom; - lhf_Put2Storage_and_AssignId(ret); - aMap_ModuleOfOccurrence2NameRoomRoot.insert(std::pair< const Ce_id, Type_id>(i_nModuleOfOccurrence,ret.TypeId())); - return ret; -} - -TypeAdmin::TypeAdmin() - : pStorage(new Type_Storage), - pCes(0), // Needs to be set directly after creation. - nXNameRoom_Root( static_cast<ary::Rid>(predefined::type_Root_ofXNameRooms) ), - nXNameRoom_Global( static_cast<ary::Rid>(predefined::type_GlobalXNameRoom) ), - aMap_ModuleOfOccurrence2NameRoomRoot() -{ - DYN ExplicitNameRoom & - drRoot = *new ExplicitNameRoom; - Storage().Set_Reserved( nXNameRoom_Root.Value(), drRoot ); - - DYN ExplicitNameRoom & - drGlobal = *new ExplicitNameRoom(String::Null_(), drRoot); - Storage().Set_Reserved( nXNameRoom_Global.Value(), drGlobal ); - drRoot.Add_Name( drGlobal.Name(), nXNameRoom_Global ); - - lhf_Setup_BuildInTypes(); -} - -TypeAdmin::~TypeAdmin() -{ -} - -void -TypeAdmin::lhf_Setup_BuildInTypes() -{ - lhf_CheckIn_BuiltInType("any", predefined::type_any); - lhf_CheckIn_BuiltInType("boolean", predefined::type_boolean); - lhf_CheckIn_BuiltInType("byte", predefined::type_byte); - lhf_CheckIn_BuiltInType("char", predefined::type_char); - lhf_CheckIn_BuiltInType("double", predefined::type_double); - lhf_CheckIn_BuiltInType("float", predefined::type_float); - lhf_CheckIn_BuiltInType("hyper", predefined::type_hyper); - lhf_CheckIn_BuiltInType("long", predefined::type_long); - lhf_CheckIn_BuiltInType("short", predefined::type_short); - lhf_CheckIn_BuiltInType("string", predefined::type_string); - lhf_CheckIn_BuiltInType("type", predefined::type_type); - lhf_CheckIn_BuiltInType("void", predefined::type_void); - lhf_CheckIn_BuiltInType("unsigned hyper", predefined::type_u_hyper); - lhf_CheckIn_BuiltInType("unsigned long", predefined::type_u_long); - lhf_CheckIn_BuiltInType("unsigned short", predefined::type_u_short); -} - -const Type & -TypeAdmin::CheckIn_Type( QualifiedName & i_rFullName, - uintt i_nSequenceCount, - Ce_id i_nModuleOfOccurrence, - const std::vector<Type_id> * i_templateParameters ) -{ - // Look in built-in types: - Type_id - nType = lhf_findBuiltInType(i_rFullName.LocalName()); - if (NOT nType.IsValid()) - { // No built-in type: - ExplicitNameRoom & - rNameRoom = lhf_CheckIn_XNameRoom(i_rFullName,i_nModuleOfOccurrence); - nType = lhf_CheckIn_TypeName( i_rFullName.LocalName(), - rNameRoom, - i_nModuleOfOccurrence, - i_templateParameters ); - } // endif - - for ( uintt s = 0; s < i_nSequenceCount; ++s ) - { - nType = lhf_CheckIn_Sequence(nType); - } - - return Storage()[nType]; -} - -TemplateParamType & -TypeAdmin::Store_TemplateParamType( String i_sName ) -{ - DYN TemplateParamType & - ret = *new TemplateParamType( i_sName ); - lhf_Put2Storage_and_AssignId(ret); - return ret; -} - -const Type & -TypeAdmin::Find_Type( Type_id i_nType ) const -{ - return Storage()[i_nType]; -} - -String -TypeAdmin::Search_LocalNameOf( Type_id i_nType ) const -{ - const Type * - pType = Storage().Exists(i_nType) - ? 0 - : & Storage()[i_nType]; - if (pType != 0) - { - switch (pType->AryClass()) - { - case Ce_Type::class_id: - case ExplicitType::class_id: - case BuiltInType::class_id: - return static_cast< const Named_Type& >(*pType).Name(); - } - } - return String::Null_(); -} - -Ce_id -TypeAdmin::Search_CeRelatedTo( Type_id i_nType ) const -{ - const Ce_Type * - ret = ary_cast<Ce_Type>( & Storage()[i_nType] ); - return ret != 0 - ? ret->RelatedCe() - : Ce_id_Null(); -} - -const ExplicitNameRoom & -TypeAdmin::Find_XNameRoom( Type_id i_nType ) const -{ - return find_ExplicitNameRoom(i_nType); -} - -bool -TypeAdmin::IsBuiltInOrRelated( const Type & i_rType ) const -{ - if ( is_type<BuiltInType>(i_rType) ) - return true; - else - { - const Type * - pType = &i_rType; - while (is_type<Sequence>(*pType)) - { - Type_id - nt = ary_cast<Sequence>(pType)->RelatedType(); - if (NOT nt.IsValid()) - return false; - pType = & Storage()[nt]; - } - return is_type<BuiltInType>(*pType); - } -} - - -String -MakeTemplateName( const String & i_localName ) -{ - StreamLock - sl(200); - - // This is the simple solution, assuming that there is only - // one version of templatisation allowed with a given name. - return - sl() - << i_localName - << C_cTemplateDelimiter - << c_str; -} - - - -} // namespace idl -} // namespace ary - -/* vim:set shiftwidth=4 softtabstop=4 expandtab: */ diff --git a/autodoc/source/ary/idl/ia_type.hxx b/autodoc/source/ary/idl/ia_type.hxx deleted file mode 100644 index 5f12eb319a22..000000000000 --- a/autodoc/source/ary/idl/ia_type.hxx +++ /dev/null @@ -1,164 +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 ARY_IDL_IA_TYPE_HXX -#define ARY_IDL_IA_TYPE_HXX - - -// USED SERVICES - // BASE CLASSES -#include <ary/idl/ip_type.hxx> - // COMPONENTS - // PARAMETERS -#include "is_type.hxx" - - -namespace ary -{ -namespace idl -{ - - -class Type_Storage; -class CeAdmin; -class TemplateParamType; - - -class TypeAdmin : public TypePilot -{ - public: - // LIFECYCLE - TypeAdmin(); - - void Assign_CePilot( - CeAdmin & io_rCes ); - virtual ~TypeAdmin(); - - // OPERATIONS - TemplateParamType & Store_TemplateParamType( - String i_sName ); - // INQUIRY - const Type_Storage & - Storage() const; - // ACCESS - Type_Storage & Storage(); - - // INHERITED - // Interface TypePilot: - virtual const Type & - CheckIn_Type( - QualifiedName & i_rFullName, - uintt i_nSequenceCount, - Ce_id i_nModuleOfOccurrence, - const std::vector<Type_id> * - i_templateParameters ); - virtual const Type & - Find_Type( - Type_id i_nType ) const; - virtual String Search_LocalNameOf( - Type_id i_nType ) const; - virtual Ce_id Search_CeRelatedTo( - Type_id i_nType ) const; - virtual const ExplicitNameRoom & - Find_XNameRoom( - Type_id i_nType ) const; - virtual bool IsBuiltInOrRelated( - const Type & i_rType ) const; - private: - // Locals - CeAdmin & my_Ces() const; - - void lhf_Put2Storage_and_AssignId( - DYN Type & pass_io_rType ); - - ExplicitNameRoom & lhf_CheckIn_XNameRoom( - const QualifiedName & - i_rName, - Ce_id i_nModuleOfOccurrence ); - Type_id lhf_CheckIn_TypeName( - const String & i_sLocalName, - ExplicitNameRoom & io_rExplicitNameRoom, - Ce_id i_nModuleOfOccurrence, - const std::vector<Type_id> * - i_templateParameters ); - Type_id lhf_CheckIn_Sequence( - Type_id i_nType ); - void lhf_CheckIn_BuiltInType( - const char * i_sName, - Rid i_nId ); - const ExplicitNameRoom & - find_ExplicitNameRoom( - Type_id i_nType ) const; - ExplicitNameRoom & find_ExplicitNameRoom( - Type_id i_nType ); - ExplicitNameRoom & lhf_Get_NameRoomRoot_forModuleofOccurrence( - Ce_id i_nModuleOfOccurrence ); - - /// @return Type_id::Null_(), if not found. - Type_id lhf_findBuiltInType( - const String & i_sName ); - /// @precond nGlobalNamespace must be valid. - void lhf_Setup_BuildInTypes(); - - // DATA - Type_Storage * pStorage; /// @inv pStorage != 0 - CeAdmin * pCes; /// @inv pCes != 0 - - // Data for saving time: - Type_id nXNameRoom_Root; /** @descr This is different from nXNameRoom_Global, because - the root of explicit name rooms in code without leading "::" is unknown. - */ - Type_id nXNameRoom_Global; - - // HACK, because this needs to be saved somehow and is not in storage: - std::map<Ce_id, Type_id> - aMap_ModuleOfOccurrence2NameRoomRoot; -}; - - - - - -// IMPLEMENTATION -inline const Type_Storage & -TypeAdmin::Storage() const -{ - return *pStorage; -} - -inline Type_Storage & -TypeAdmin::Storage() -{ - return *pStorage; -} - -inline void -TypeAdmin::Assign_CePilot( CeAdmin & io_rCes ) -{ - pCes = &io_rCes; -} - - - - -} // namespace idl -} // namespace ary -#endif - -/* vim:set shiftwidth=4 softtabstop=4 expandtab: */ diff --git a/autodoc/source/ary/idl/is_ce.cxx b/autodoc/source/ary/idl/is_ce.cxx deleted file mode 100644 index 068fc2be6904..000000000000 --- a/autodoc/source/ary/idl/is_ce.cxx +++ /dev/null @@ -1,59 +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 . - */ - -#include <precomp.h> -#include "is_ce.hxx" - -// NOT FULLY DEFINED SERVICES - -namespace -{ - const uintt - C_nReservedElements = ary::idl::predefined::ce_MAX; // Skipping "0" and the GlobalNamespace -} - - -namespace ary -{ -namespace idl -{ - -Ce_Storage * Ce_Storage::pInstance_ = 0; - - - - -Ce_Storage::Ce_Storage() - : stg::Storage<CodeEntity>(C_nReservedElements) -{ - csv_assert(pInstance_ == 0); - pInstance_ = this; -} - -Ce_Storage::~Ce_Storage() -{ - csv_assert(pInstance_ != 0); - pInstance_ = 0; -} - - -} // namespace idl -} // namespace ary - -/* vim:set shiftwidth=4 softtabstop=4 expandtab: */ diff --git a/autodoc/source/ary/idl/is_ce.hxx b/autodoc/source/ary/idl/is_ce.hxx deleted file mode 100644 index 3dc04c3dd47e..000000000000 --- a/autodoc/source/ary/idl/is_ce.hxx +++ /dev/null @@ -1,73 +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 ARY_IDL_IS_CE_HXX -#define ARY_IDL_IS_CE_HXX - -// BASE CLASSES -#include <store/s_storage.hxx> -// USED SERVICES -#include <ary/idl/i_ce.hxx> - - - - -namespace ary -{ -namespace idl -{ - - -/** The data base for all ->ary::idl::CodeEntity objects. -*/ -class Ce_Storage : public ::ary::stg::Storage< ::ary::idl::CodeEntity > -{ - public: - Ce_Storage(); - virtual ~Ce_Storage(); - - static Ce_Storage & Instance_() { csv_assert(pInstance_ != 0); - return *pInstance_; } - private: - // DATA - static Ce_Storage * pInstance_; -}; - - - - -namespace predefined -{ - -enum E_CodeEntity -{ - ce_GlobalNamespace = 1, - ce_MAX -}; - -} // namespace predefined - - - - -} // namespace idl -} // namespace ary -#endif - -/* vim:set shiftwidth=4 softtabstop=4 expandtab: */ diff --git a/autodoc/source/ary/idl/is_type.cxx b/autodoc/source/ary/idl/is_type.cxx deleted file mode 100644 index 959a6384301b..000000000000 --- a/autodoc/source/ary/idl/is_type.cxx +++ /dev/null @@ -1,77 +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 . - */ - -#include <precomp.h> -#include "is_type.hxx" - - -// NOT FULLY DEFINED SERVICES -#include <cosv/tpl/tpltools.hxx> - -namespace -{ - -const uintt - C_nReservedElements = ary::idl::predefined::type_MAX; // Skipping "0" and the built in types. -} - - -namespace ary -{ -namespace idl -{ - -Type_Storage * Type_Storage::pInstance_ = 0; - - - -Type_Storage::Type_Storage() - : stg::Storage<Type>(C_nReservedElements), - aSequenceIndex() -{ - csv_assert(pInstance_ == 0); - pInstance_ = this; -} - -Type_Storage::~Type_Storage() -{ - csv_assert(pInstance_ != 0); - pInstance_ = 0; -} - -void -Type_Storage::Add_Sequence( Type_id i_nRelatedType, - Type_id i_nSequence ) -{ - aSequenceIndex[i_nRelatedType] = i_nSequence; -} - -Type_id -Type_Storage::Search_SequenceOf( Type_id i_nRelatedType ) -{ - return csv::value_from_map(aSequenceIndex, i_nRelatedType); -} - - - - -} // namespace idl -} // namespace ary - -/* vim:set shiftwidth=4 softtabstop=4 expandtab: */ diff --git a/autodoc/source/ary/idl/is_type.hxx b/autodoc/source/ary/idl/is_type.hxx deleted file mode 100644 index 1b7766ee310a..000000000000 --- a/autodoc/source/ary/idl/is_type.hxx +++ /dev/null @@ -1,116 +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 ARY_IDL_IS_TYPE_HXX -#define ARY_IDL_IS_TYPE_HXX - -// BASE CLASSES -#include <store/s_storage.hxx> -// USED SERVICES -#include <ary/idl/i_type.hxx> - - - - -namespace ary -{ -namespace idl -{ - - -/** The data base for all ->ary::idl::CodeEntity objects. -*/ -class Type_Storage : public ::ary::stg::Storage< ::ary::idl::Type > -{ - public: - Type_Storage(); - ~Type_Storage(); - - - void Add_Sequence( - Type_id i_nRelatedType, - Type_id i_nSequence ); - - Type_id Search_SequenceOf( - Type_id i_nRelatedType ); - - static Type_Storage & - Instance_(); - private: - /** value_type.first := id of the base type - value_type.second := id of the sequence<base type> - */ - typedef std::map<Type_id,Type_id> Map_Sequences; - - // DATA - Map_Sequences aSequenceIndex; - - static Type_Storage * - pInstance_; -}; - - - -namespace predefined -{ - -enum E_Type -{ - type_Root_ofXNameRooms = 1, - type_GlobalXNameRoom, - type_any, - type_boolean, - type_byte, - type_char, - type_double, - type_float, - type_hyper, - type_long, - type_short, - type_string, - type_type, - type_void, - type_u_hyper, - type_u_long, - type_u_short, - type_ellipse, // ... - type_MAX -}; - -} // namespace predefined - - - - -// IMPLEMENTATION -inline Type_Storage & -Type_Storage::Instance_() -{ - csv_assert(pInstance_ != 0); - return *pInstance_; -} - - - - -} // namespace idl -} // namespace ary -#endif - -/* vim:set shiftwidth=4 softtabstop=4 expandtab: */ diff --git a/autodoc/source/ary/idl/it_builtin.cxx b/autodoc/source/ary/idl/it_builtin.cxx deleted file mode 100644 index 7dd941a3538a..000000000000 --- a/autodoc/source/ary/idl/it_builtin.cxx +++ /dev/null @@ -1,73 +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 . - */ - -#include <precomp.h> -#include "it_builtin.hxx" - - -// NOT FULLY DEFINED SERVICES -#include <cosv/tpl/processor.hxx> - - - -namespace ary -{ -namespace idl -{ - - - -BuiltInType::BuiltInType( const char * i_sName ) - : Named_Type(i_sName) -{ -} - -BuiltInType::~BuiltInType() -{ -} - -ClassId -BuiltInType::get_AryClass() const -{ - return class_id; -} - -void -BuiltInType::do_Accept( csv::ProcessorIfc & io_processor ) const -{ - csv::CheckedCall(io_processor, *this); -} - -void -BuiltInType::inq_Get_Text( StringVector & , // o_module - String & o_name, - Ce_id & , // o_nRelatedCe - int & , // o_nSequenceCount - const Gate & ) const // i_rGate -{ - o_name = Name(); -} - - - - -} // namespace idl -} // namespace ary - -/* vim:set shiftwidth=4 softtabstop=4 expandtab: */ diff --git a/autodoc/source/ary/idl/it_builtin.hxx b/autodoc/source/ary/idl/it_builtin.hxx deleted file mode 100644 index d9db79467c5f..000000000000 --- a/autodoc/source/ary/idl/it_builtin.hxx +++ /dev/null @@ -1,70 +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 ARY_IDL_IT_BUILTIN_HXX -#define ARY_IDL_IT_BUILTIN_HXX - -// BASE CLASSES -#include "it_named.hxx" - - - - -namespace ary -{ -namespace idl -{ - - -/** A type defined by the IDL language. -*/ -class BuiltInType : public Named_Type -{ - public: - enum E_ClassId { class_id = 2200 }; - - // LIFECYCLE - BuiltInType( - const char * i_sName ); - virtual ~BuiltInType(); - - private: - // Interface csv::ConstProcessorClient: - virtual void do_Accept( - csv::ProcessorIfc & io_processor ) const; - // Interface Object: - virtual ClassId get_AryClass() const; - - // Interface Type: - virtual void inq_Get_Text( - StringVector & o_module, - String & o_name, - Ce_id & o_nRelatedCe, - int & o_nSequenceCount, - const Gate & i_rGate ) const; -}; - - - - -} // namespace idl -} // namespace ary -#endif - -/* vim:set shiftwidth=4 softtabstop=4 expandtab: */ diff --git a/autodoc/source/ary/idl/it_ce.cxx b/autodoc/source/ary/idl/it_ce.cxx deleted file mode 100644 index f0861d11d51e..000000000000 --- a/autodoc/source/ary/idl/it_ce.cxx +++ /dev/null @@ -1,94 +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 . - */ - -#include <precomp.h> -#include "it_ce.hxx" - - -// NOT FULLY DEFINED SERVICES -#include <cosv/tpl/processor.hxx> -#include <ary/idl/i_ce.hxx> -#include <ary/idl/i_gate.hxx> -#include <ary/idl/i_module.hxx> -#include <ary/idl/ip_ce.hxx> - - - -namespace ary -{ -namespace idl -{ - - -Ce_Type::Ce_Type( Ce_id i_relatedCe, - const std::vector<Type_id> * i_templateParameters ) - : nRelatedCe(i_relatedCe), - pTemplateParameters(0) -{ - if (i_templateParameters != 0) - pTemplateParameters = new std::vector<Type_id>(*i_templateParameters); -} - -Ce_Type::~Ce_Type() -{ -} - -ClassId -Ce_Type::get_AryClass() const -{ - return class_id; -} - -void -Ce_Type::do_Accept( csv::ProcessorIfc & io_processor ) const -{ - csv::CheckedCall(io_processor, *this); -} - -void -Ce_Type::inq_Get_Text( StringVector & o_module, - String & o_name, - Ce_id & o_nRelatedCe, - int & , // o_nSequenceCount - const Gate & i_rGate ) const -{ - String sDummyMember; - - const CodeEntity & - rCe = i_rGate.Ces().Find_Ce(nRelatedCe); - i_rGate.Ces().Get_Text( o_module, - o_name, - sDummyMember, - rCe ); - o_nRelatedCe = nRelatedCe; -} - -const std::vector<Type_id> * -Ce_Type::inq_TemplateParameters() const -{ - return pTemplateParameters.Ptr(); -} - - - - -} // namespace idl -} // namespace ary - -/* vim:set shiftwidth=4 softtabstop=4 expandtab: */ diff --git a/autodoc/source/ary/idl/it_ce.hxx b/autodoc/source/ary/idl/it_ce.hxx deleted file mode 100644 index c3cfdf860b22..000000000000 --- a/autodoc/source/ary/idl/it_ce.hxx +++ /dev/null @@ -1,82 +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 ARY_IDL_IT_CE_HXX -#define ARY_IDL_IT_CE_HXX - -// BASE CLASSES -#include <ary/idl/i_type.hxx> - - - - -namespace ary -{ -namespace idl -{ - - -/** A named ->Type related to its corresponding - ->CodeEntity. -*/ -class Ce_Type : public Type -{ - public: - enum E_ClassId { class_id = 2201 }; - - // LIFECYCLE - Ce_Type( - Ce_id i_relatedCe, - const std::vector<Type_id> * - i_templateParameters ); - virtual ~Ce_Type(); - - // INQUIRY - Ce_id RelatedCe() const { return nRelatedCe; } - - private: - // Interface csv::ConstProcessorClient: - virtual void do_Accept( - csv::ProcessorIfc & io_processor ) const; - // Interface Object: - virtual ClassId get_AryClass() const; - - // Interface Type: - virtual void inq_Get_Text( - StringVector & o_module, - String & o_name, - Ce_id & o_nRelatedCe, - int & o_nSequemceCount, - const Gate & i_rGate ) const; - virtual const std::vector<Type_id> * - inq_TemplateParameters() const; - // DATA - Ce_id nRelatedCe; - Dyn< std::vector<Type_id> > - pTemplateParameters; -}; - - - - -} // namespace idl -} // namespace ary -#endif - -/* vim:set shiftwidth=4 softtabstop=4 expandtab: */ diff --git a/autodoc/source/ary/idl/it_explicit.cxx b/autodoc/source/ary/idl/it_explicit.cxx deleted file mode 100644 index 3a4ad53bebb7..000000000000 --- a/autodoc/source/ary/idl/it_explicit.cxx +++ /dev/null @@ -1,94 +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 . - */ - -#include <precomp.h> -#include "it_explicit.hxx" - - -// NOT FULLY DEFINED SERVICES -#include <cosv/tpl/processor.hxx> -#include <ary/idl/i_module.hxx> -#include <ary/idl/i_gate.hxx> -#include <ary/idl/ip_ce.hxx> -#include <ary/idl/ip_type.hxx> -#include "it_xnameroom.hxx" - - - -namespace ary -{ -namespace idl -{ - - -ExplicitType::ExplicitType( const String & i_sName, - Type_id i_nXNameRoom, - Ce_id i_nModuleOfOccurrence, - const std::vector<Type_id> * - i_templateParameters ) - : Named_Type(i_sName), - nXNameRoom(i_nXNameRoom), - nModuleOfOccurrence(i_nModuleOfOccurrence), - pTemplateParameters(0) -{ - if (i_templateParameters != 0) - pTemplateParameters = new std::vector<Type_id>(*i_templateParameters); -} - -ExplicitType::~ExplicitType() -{ -} - -ClassId -ExplicitType::get_AryClass() const -{ - return class_id; -} - -void -ExplicitType::do_Accept( csv::ProcessorIfc & io_processor ) const -{ - csv::CheckedCall(io_processor, *this); -} - -void -ExplicitType::inq_Get_Text( StringVector & o_module, - String & o_name, - Ce_id & o_nRelatedCe, - int & o_nSequenceCount, - const Gate & i_rGate ) const -{ - const ExplicitNameRoom & - rNameRoom = i_rGate.Types().Find_XNameRoom(nXNameRoom); - rNameRoom.Get_Text(o_module,o_name,o_nRelatedCe,o_nSequenceCount,i_rGate); - - o_name = Name(); -} - -const std::vector<Type_id> * -ExplicitType::inq_TemplateParameters() const -{ - return pTemplateParameters.Ptr(); -} - - -} // namespace idl -} // namespace ary - -/* vim:set shiftwidth=4 softtabstop=4 expandtab: */ diff --git a/autodoc/source/ary/idl/it_explicit.hxx b/autodoc/source/ary/idl/it_explicit.hxx deleted file mode 100644 index 6538f07a5483..000000000000 --- a/autodoc/source/ary/idl/it_explicit.hxx +++ /dev/null @@ -1,87 +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 ARY_IDL_IT_EXPLICIT_HXX -#define ARY_IDL_IT_EXPLICIT_HXX - -// BASE CLASSES -#include "it_named.hxx" - - - - -namespace ary -{ -namespace idl -{ - - -/** A named @->Type, not yet related to its corresponding - @->CodeEntity. -*/ -class ExplicitType : public Named_Type -{ - public: - enum E_ClassId { class_id = 2203 }; - - // LIFECYCLE - ExplicitType( - const String & i_sName, - Type_id i_nXNameRoom, - Ce_id i_nModuleOfOccurrence, - const std::vector<Type_id> * - i_templateParameters ); - virtual ~ExplicitType(); - - // INQUIRY - Ce_id ModuleOfOccurrence() const - { return nModuleOfOccurrence; } - Type_id NameRoom() const { return nXNameRoom; } - - private: - // Interface csv::ConstProcessorClient: - virtual void do_Accept( - csv::ProcessorIfc & io_processor ) const; - // Interface CppEntity: - virtual ClassId get_AryClass() const; - - // Interface Type: - virtual void inq_Get_Text( - StringVector & o_module, - String & o_name, - Ce_id & o_nRelatedCe, - int & o_nSequemceCount, - const Gate & i_rGate ) const; - virtual const std::vector<Type_id> * - inq_TemplateParameters() const; - // DATA - Type_id nXNameRoom; // As written in code. - Ce_id nModuleOfOccurrence; - Dyn< const std::vector<Type_id> > - pTemplateParameters; -}; - - - - -} // namespace idl -} // namespace ary -#endif - -/* vim:set shiftwidth=4 softtabstop=4 expandtab: */ diff --git a/autodoc/source/ary/idl/it_named.hxx b/autodoc/source/ary/idl/it_named.hxx deleted file mode 100644 index 0119d45130ef..000000000000 --- a/autodoc/source/ary/idl/it_named.hxx +++ /dev/null @@ -1,69 +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 ARY_IDL_IT_NAMED_HXX -#define ARY_IDL_IT_NAMED_HXX - - - -// USED SERVICES - // BASE CLASSES -#include <ary/idl/i_type.hxx> - // COMPONENTS - // PARAMETERS - - -namespace ary -{ -namespace idl -{ - - - - -/** Represents types with a name - in opposite to e.g. sequences, - which do not have one. -*/ -class Named_Type : public Type -{ - public: - // LIFECYCLE - virtual ~Named_Type() {} - - // INQUIRY - const String & Name() const { return sName; } - - protected: - Named_Type( - const String & i_sName ) - : sName(i_sName) { } - private: - // DATA - String sName; -}; - - - -} // namespace idl -} // namespace ary - - -#endif - -/* vim:set shiftwidth=4 softtabstop=4 expandtab: */ diff --git a/autodoc/source/ary/idl/it_sequence.cxx b/autodoc/source/ary/idl/it_sequence.cxx deleted file mode 100644 index c95b3183ea61..000000000000 --- a/autodoc/source/ary/idl/it_sequence.cxx +++ /dev/null @@ -1,85 +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 . - */ - -#include <precomp.h> -#include "it_sequence.hxx" - - -// NOT FULLY DEFINED SERVICES -#include <cosv/tpl/processor.hxx> -#include <ary/idl/i_gate.hxx> -#include <ary/idl/ip_type.hxx> - - - -namespace ary -{ -namespace idl -{ - - -Sequence::Sequence( Type_id i_nRelatedType ) - : nRelatedType(i_nRelatedType) -{ -} - -Sequence::~Sequence() -{ -} - -ClassId -Sequence::get_AryClass() const -{ - return class_id; -} - -void -Sequence::do_Accept( csv::ProcessorIfc & io_processor ) const -{ - csv::CheckedCall(io_processor, *this); -} - -void -Sequence::inq_Get_Text( StringVector & o_module, - String & o_name, - Ce_id & o_nRelatedCe, - int & o_nSequenceCount, - const Gate & i_rGate ) const -{ - ++o_nSequenceCount; - - i_rGate.Types().Find_Type(nRelatedType) - .Get_Text( o_module, - o_name, - o_nRelatedCe, - o_nSequenceCount, - i_rGate ); -} - -const Type & -Sequence::inq_FirstEnclosedNonSequenceType(const Gate & i_rGate) const -{ - return i_rGate.Types().Find_Type(nRelatedType).FirstEnclosedNonSequenceType(i_rGate); -} - - -} // namespace idl -} // namespace ary - -/* vim:set shiftwidth=4 softtabstop=4 expandtab: */ diff --git a/autodoc/source/ary/idl/it_sequence.hxx b/autodoc/source/ary/idl/it_sequence.hxx deleted file mode 100644 index a4933601e335..000000000000 --- a/autodoc/source/ary/idl/it_sequence.hxx +++ /dev/null @@ -1,78 +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 ARY_IDL_IT_SEQUENCE_HXX -#define ARY_IDL_IT_SEQUENCE_HXX - -// BASE CLASSES -#include <ary/idl/i_type.hxx> - - - - -namespace ary -{ -namespace idl -{ - - -/** A sequence (an array of a type). -*/ -class Sequence : public Type -{ - public: - enum E_ClassId { class_id = 2202 }; - - // LIFECYCLE - Sequence( - Type_id i_nRelatedType ); - virtual ~Sequence(); - - // INQUIRY - Type_id RelatedType() const { return nRelatedType; } - - private: - // Interface csv::ConstProcessorClient: - virtual void do_Accept( - csv::ProcessorIfc & io_processor ) const; - // Interface Object: - virtual ClassId get_AryClass() const; - - // Interface Type: - virtual void inq_Get_Text( - StringVector & o_module, - String & o_name, - Ce_id & o_nRelatedCe, - int & o_nSequemceCount, - const Gate & i_rGate ) const; - virtual const Type & - inq_FirstEnclosedNonSequenceType( - const Gate & i_rGate ) const; - // DATA - Type_id nRelatedType; -}; - - - - -} // namespace idl -} // namespace ary -#endif - -/* vim:set shiftwidth=4 softtabstop=4 expandtab: */ diff --git a/autodoc/source/ary/idl/it_tplparam.cxx b/autodoc/source/ary/idl/it_tplparam.cxx deleted file mode 100644 index 8b47ee43e02f..000000000000 --- a/autodoc/source/ary/idl/it_tplparam.cxx +++ /dev/null @@ -1,86 +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 . - */ - -#include <precomp.h> -#include "it_tplparam.hxx" - - -// NOT FULLY DEFINED SERVICES -#include <cosv/tpl/processor.hxx> - - - -namespace ary -{ -namespace idl -{ - - - -TemplateParamType::TemplateParamType( const char * i_sName ) - : Named_Type(i_sName) -{ -} - -TemplateParamType::~TemplateParamType() -{ -} - -ClassId -TemplateParamType::get_AryClass() const -{ - return class_id; -} - -void -TemplateParamType::do_Accept( csv::ProcessorIfc & io_processor ) const -{ - csv::CheckedCall(io_processor, *this); -} - -void -TemplateParamType::inq_Get_Text( StringVector & , // o_module - String & o_name, - Ce_id & , // o_nRelatedCe - int & , // o_nSequenceCount - const Gate & ) const // i_rGate -{ - o_name = Name(); -} - - -//************* Implemented default function for idl::Type ********// - -const std::vector<Type_id> * -Type::inq_TemplateParameters() const -{ - return 0; -} - -const Type & -Type::inq_FirstEnclosedNonSequenceType(const Gate & ) const -{ - return *this; -} - - -} // namespace idl -} // namespace ary - -/* vim:set shiftwidth=4 softtabstop=4 expandtab: */ diff --git a/autodoc/source/ary/idl/it_tplparam.hxx b/autodoc/source/ary/idl/it_tplparam.hxx deleted file mode 100644 index e38fcfed1f15..000000000000 --- a/autodoc/source/ary/idl/it_tplparam.hxx +++ /dev/null @@ -1,92 +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 ARY_IDL_IT_TPLPARAM_HXX -#define ARY_IDL_IT_TPLPARAM_HXX - -// BASE CLASSES -#include "it_named.hxx" - - - - -namespace ary -{ -namespace idl -{ - - -/** @resp Represents a template type when it is used within the - declaring struct. -*/ -class TemplateParamType : public Named_Type -{ - public: - enum E_ClassId { class_id = 2205 }; - - // LIFECYCLE - TemplateParamType( - const char * i_sName ); - virtual ~TemplateParamType(); - - Ce_id StructId() const; /// The struct which declares this type. - void Set_StructId( - Ce_id i_nStruct ); - private: - // Interface csv::ConstProcessorClient: - virtual void do_Accept( - csv::ProcessorIfc & io_processor ) const; - // Interface Object: - virtual ClassId get_AryClass() const; - - // Interface Type: - virtual void inq_Get_Text( - StringVector & o_module, - String & o_name, - Ce_id & o_nRelatedCe, - int & o_nSequenceCount, - const Gate & i_rGate ) const; - // DATA - Ce_id nStruct; /// The struct which declares this type. -}; - - - - -// IMPLEMENTATION -inline Ce_id -TemplateParamType::StructId() const -{ - return nStruct; -} - -inline void -TemplateParamType::Set_StructId( Ce_id i_nStruct ) -{ - nStruct = i_nStruct; -} - - - - -} // namespace idl -} // namespace ary -#endif - -/* vim:set shiftwidth=4 softtabstop=4 expandtab: */ diff --git a/autodoc/source/ary/idl/it_xnameroom.cxx b/autodoc/source/ary/idl/it_xnameroom.cxx deleted file mode 100644 index e3d265de9bad..000000000000 --- a/autodoc/source/ary/idl/it_xnameroom.cxx +++ /dev/null @@ -1,94 +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 . - */ - -#include <precomp.h> -#include "it_xnameroom.hxx" - - -// NOT FULLY DEFINED SERVICES -#include <cosv/tpl/processor.hxx> -#include <cosv/tpl/tpltools.hxx> -#include <ary/idl/i_gate.hxx> -#include <ary/idl/ip_type.hxx> - - - -namespace ary -{ -namespace idl -{ - - -ExplicitNameRoom::ExplicitNameRoom() - : aImpl() -{ -} - -ExplicitNameRoom::ExplicitNameRoom( const String & i_sName, - const ExplicitNameRoom & i_rParent ) - : aImpl( i_sName, i_rParent.aImpl, i_rParent.TypeId() ) -{ -} - -ExplicitNameRoom::~ExplicitNameRoom() -{ -} - -ClassId -ExplicitNameRoom::get_AryClass() const -{ - return class_id; -} - -void -ExplicitNameRoom::do_Accept( csv::ProcessorIfc & io_processor ) const -{ - csv::CheckedCall(io_processor, *this); -} - -void -ExplicitNameRoom::inq_Get_Text( StringVector & o_module, - String & , // o_name - Ce_id & , // o_nRelatedCe - int & , // o_nSequemceCount - const Gate & ) const // i_rGate -{ - StringVector::const_iterator it = NameChain_Begin(); - if ( it != NameChain_End() - ? (*it).empty() - : false ) - { // Don't put out the root global namespace - ++it; - } - - for ( ; - it != NameChain_End(); - ++it ) - { - o_module.push_back(*it); - } -} - - - - -} // namespace idl -} // namespace ary - -/* vim:set shiftwidth=4 softtabstop=4 expandtab: */ diff --git a/autodoc/source/ary/idl/it_xnameroom.hxx b/autodoc/source/ary/idl/it_xnameroom.hxx deleted file mode 100644 index e827d4814980..000000000000 --- a/autodoc/source/ary/idl/it_xnameroom.hxx +++ /dev/null @@ -1,117 +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 ARY_IDL_IT_XNAMEROOM_HXX -#define ARY_IDL_IT_XNAMEROOM_HXX - -// BASE CLASSES -#include <ary/idl/i_type.hxx> -#include <nametreenode.hxx> - - - - -namespace ary -{ -namespace idl -{ - - -/** A namespace for ->Type s, as they are explicitly written in code. - - The search/identification string is usually the local name of - the Type. But for templated structs, the search string has this - pattern: - <LocalName> '<' <StringOfTemplateTypeId> -*/ -class ExplicitNameRoom : public Type -{ - public: - enum E_ClassId { class_id = 2204 }; - - // LIFECYCLE - ExplicitNameRoom(); - ExplicitNameRoom( - const String & i_sName, - const ExplicitNameRoom & - i_rParent ); - virtual ~ExplicitNameRoom(); - - // OPERATIONS - /** @param i_sSearchString - A local type name usually. - For templated types see class docu. - @see ExplicitNameRoom - */ - void Add_Name( - const String & i_sSearchString, - Type_id i_nId ) - { aImpl.Add_Name(i_sSearchString,i_nId); } - // INQUIRY - const String & Name() const { return aImpl.Name(); } - intt Depth() const { return aImpl.Depth(); } - void Get_FullName( - StringVector & o_rText, - Ce_idList * o_pRelatedCes, - const Gate & i_rGate ) const; - bool IsAbsolute() const { return Depth() > 0 - ? (*NameChain_Begin()).empty() - : false; } - /** @param i_sSearchString - A local type name usually. - For templated types see class docu. - @see ExplicitNameRoom - */ - Type_id Search_Name( - const String & i_sSearchString ) const - { return aImpl.Search_Name(i_sSearchString); } - - StringVector::const_iterator - NameChain_Begin() const - { return aImpl.NameChain_Begin(); } - StringVector::const_iterator - NameChain_End() const - { return aImpl.NameChain_End(); } - private: - // Interface csv::ConstProcessorClient: - virtual void do_Accept( - csv::ProcessorIfc & io_processor ) const; - // Interface Object: - virtual ClassId get_AryClass() const; - - // Interface Type: - virtual void inq_Get_Text( - StringVector & o_module, - String & o_name, - Ce_id & o_nRelatedCe, - int & o_nSequemceCount, - const Gate & i_rGate ) const; - // DATA - NameTreeNode<Type_id> - aImpl; -}; - - - - -} // namespace idl -} // namespace ary -#endif - -/* vim:set shiftwidth=4 softtabstop=4 expandtab: */ diff --git a/autodoc/source/ary/inc/idl_internalgate.hxx b/autodoc/source/ary/inc/idl_internalgate.hxx deleted file mode 100644 index 23e6dff26640..000000000000 --- a/autodoc/source/ary/inc/idl_internalgate.hxx +++ /dev/null @@ -1,51 +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 ARY_IDL_INTERNALGATE_HXX -#define ARY_IDL_INTERNALGATE_HXX - -// BASE CLASSES -#include <ary/idl/i_gate.hxx> - -namespace ary -{ -namespace idl -{ - - -/** Provides access to the ->idl::RepositoryPartition as far as is needed - by the ->RepositoryCenter. -*/ -class InternalGate : public ::ary::idl::Gate -{ - public: - virtual ~InternalGate() {} - - static DYN InternalGate & - Create_Partition_(); -}; - - - - -} // namespace idl -} // namespace ary -#endif - -/* vim:set shiftwidth=4 softtabstop=4 expandtab: */ diff --git a/autodoc/source/ary/inc/idsort.hxx b/autodoc/source/ary/inc/idsort.hxx deleted file mode 100644 index 327a52173f3f..000000000000 --- a/autodoc/source/ary/inc/idsort.hxx +++ /dev/null @@ -1,46 +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 ARY_IDSORT_HXX -#define ARY_IDSORT_HXX - - -/** A compare function that sorts ids of repository entities in the same - storage. - - @see ::ary::SortedIds -*/ -template<class COMPARE> -struct IdSorter -{ - bool operator()( - typename COMPARE::id_type - i_1, - typename COMPARE::id_type - i_2 ) const - { return COMPARE::Lesser_( - COMPARE::KeyOf_(COMPARE::EntityOf_(i_1)), - COMPARE::KeyOf_(COMPARE::EntityOf_(i_2)) ); - } -}; - - -#endif - -/* vim:set shiftwidth=4 softtabstop=4 expandtab: */ diff --git a/autodoc/source/ary/inc/nametreenode.hxx b/autodoc/source/ary/inc/nametreenode.hxx deleted file mode 100644 index b4d684018d76..000000000000 --- a/autodoc/source/ary/inc/nametreenode.hxx +++ /dev/null @@ -1,204 +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 ARY_NAMETREENODE_HXX -#define ARY_NAMETREENODE_HXX -// KORR_DEPRECATED_3.0 -// Replace by ::ary::symtree::Node. - -// USED SERVICES -#include <cosv/tpl/tpltools.hxx> -#include <sci_impl.hxx> -// HACK because of SunPro 5.2 compiler bug with templates: -#include <ary/idl/i_module.hxx> - - - - -namespace ary -{ - - -/** Implementation of a node in a namespace-tree. -*/ -template<class ITEM_ID> -class NameTreeNode -{ - public: - typedef NameTreeNode self; - typedef ITEM_ID item_id; - typedef StringVector::const_iterator name_iterator; - typedef std::map<String, item_id> Map_LocalNames; - - // LIFECYCLE - NameTreeNode(); - NameTreeNode( - const String & i_sName, - const self & i_rParent, - ITEM_ID i_nParentId ); - virtual ~NameTreeNode(); - - // OPERATIONS - void Add_Name( - const String & i_sName, - item_id i_nId ); - // INQUIRY - const String & Name() const { return Depth() > 0 ? aCompleteNameChain.back() : String::Null_(); } - item_id Parent() const { return nParent; } - intt Depth() const { return aCompleteNameChain.size(); } - - bool IsEquivalent( - const NameTreeNode & - i_rNode ) const; - name_iterator NameChain_Begin() const { return aCompleteNameChain.begin(); } - name_iterator NameChain_End() const { return aCompleteNameChain.end(); } - - item_id Search_Name( - const String & i_sName ) const; - void Get_Names( - Dyn_StdConstIterator<ITEM_ID> & - o_rResult ) const; - const Map_LocalNames & - LocalNames() const { return aLocalNames; } - private: - // Locals - Map_LocalNames & LocalNames() { return aLocalNames; } - - // DATA - Map_LocalNames aLocalNames; - StringVector aCompleteNameChain; - item_id nParent; -}; - - - - -// IMPLEMENTATION -template<class ITEM_ID> -NameTreeNode<ITEM_ID>::NameTreeNode() - : aLocalNames(), - aCompleteNameChain(), - nParent(0) -{ -} - -template<class ITEM_ID> -NameTreeNode<ITEM_ID>::NameTreeNode( const String & i_sName, - const self & i_rParent, - ITEM_ID i_nParentId ) - : aLocalNames(), - aCompleteNameChain(), - nParent(i_nParentId) -{ - aCompleteNameChain.reserve(i_rParent.Depth()+1); - for ( name_iterator it = i_rParent.NameChain_Begin(); - it != i_rParent.NameChain_End(); - ++it ) - { - aCompleteNameChain.push_back(*it); - } - aCompleteNameChain.push_back(i_sName); -} - -template<class ITEM_ID> -NameTreeNode<ITEM_ID>::~NameTreeNode() -{ -} - - -template<class ITEM_ID> -inline void -NameTreeNode<ITEM_ID>::Add_Name( const String & i_sName, - item_id i_nId ) -{ - LocalNames().insert( typename Map_LocalNames::value_type(i_sName, i_nId) ); -} - - -template<class ITEM_ID> -inline bool -NameTreeNode<ITEM_ID>::IsEquivalent( const NameTreeNode & i_rNode ) const -{ - return aCompleteNameChain == i_rNode.aCompleteNameChain; -} - -template<class ITEM_ID> -inline ITEM_ID -NameTreeNode<ITEM_ID>::Search_Name( const String & i_sName ) const -{ - return csv::value_from_map(LocalNames(),i_sName, ITEM_ID(0)); -} - -template<class ITEM_ID> -inline void -NameTreeNode<ITEM_ID>::Get_Names( Dyn_StdConstIterator<ITEM_ID> & o_rResult ) const -{ - o_rResult = new SCI_DataInMap<String,item_id>(LocalNames()); -} - - -// HACK because of SunPro 5.2 compiler bug with templates: -// ary::idl::Module has to be "FIND_NODE::node_type" -// must be solved later somehow. -template <class FIND_NODE> -typename FIND_NODE::id_type -Search_SubTree( const ary::idl::Module & i_rStart, - const FIND_NODE & i_rNodeFinder ) -{ - const ary::idl::Module * - ret = &i_rStart; - - for ( StringVector::const_iterator it = i_rNodeFinder.Begin(); - it != i_rNodeFinder.End() AND ret != 0; - ++it ) - { - ret = i_rNodeFinder(ret->Search_Name(*it)); - } - - typename FIND_NODE::id_type nret(0); - return ret != 0 - ? ret->Search_Name(i_rNodeFinder.Name2Search()) - : nret; -} - -template <class FIND_NODE> -typename FIND_NODE::id_type -Search_SubTree_UpTillRoot( const ary::idl::Module & i_rStart, - const FIND_NODE & i_rNodeFinder ) -{ - typename FIND_NODE::id_type - ret(0); - for ( const ary::idl::Module * start = &i_rStart; - start != 0 AND NOT ret.IsValid(); - start = i_rNodeFinder(start->Owner()) ) - { - ret = Search_SubTree( *start, - i_rNodeFinder ); - } - return ret; -} -// END Hack for SunPro 5.2 compiler bug. - - - - -} // namespace ary -#endif - -/* vim:set shiftwidth=4 softtabstop=4 expandtab: */ diff --git a/autodoc/source/ary/inc/reposy.hxx b/autodoc/source/ary/inc/reposy.hxx deleted file mode 100644 index f906cd5c255a..000000000000 --- a/autodoc/source/ary/inc/reposy.hxx +++ /dev/null @@ -1,77 +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 ARY_REPOSY_HXX -#define ARY_REPOSY_HXX - -// BASE CLASSES -#include <ary/ary.hxx> -// USED SERVICES -#include <cosv/ploc_dir.hxx> - -namespace ary -{ -namespace idl -{ - class InternalGate; -} -} // namespace ary - - - - -namespace ary -{ - - -/** Implements ::ary::Repository. - - @see Repository -*/ - -class RepositoryCenter : public ::ary::Repository -{ - public: - // LIFECYCLE - RepositoryCenter(); - virtual ~RepositoryCenter(); - - // INHERITED - // Interface Repository: - virtual const idl::Gate & Gate_Idl() const; - virtual const String & Title() const; - virtual idl::Gate & Gate_Idl(); - virtual void Set_Title(const String & i_sName ); - - private: - // DATA - String sDisplayedName; /// Name to be displayed for human users. - csv::ploc::Directory - aLocation; - Dyn<idl::InternalGate> - pIdlPartition; -}; - - - - -} // namespace ary -#endif - -/* vim:set shiftwidth=4 softtabstop=4 expandtab: */ diff --git a/autodoc/source/ary/inc/sci_impl.hxx b/autodoc/source/ary/inc/sci_impl.hxx deleted file mode 100644 index 8c766ba50ba9..000000000000 --- a/autodoc/source/ary/inc/sci_impl.hxx +++ /dev/null @@ -1,407 +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 ARY_SCI_IMPL_HXX -#define ARY_SCI_IMPL_HXX - - - -// USED SERVICES - // BASE CLASSES -#include <ary/stdconstiter.hxx> - // COMPONENTS - // PARAMETERS - - -namespace ary -{ - - -//************************* SCI_Vector **********************************// - -template <class ELEM> -class SCI_Vector : public StdConstIterator<ELEM> -{ - public: - typedef std::vector<ELEM> source; - typedef typename source::const_iterator source_iterator; - - SCI_Vector( - const source & i_rSource ); - virtual ~SCI_Vector(); - - private: - // Interface StdConstIterator<>: - virtual void do_Advance(); - virtual const ELEM * - inq_CurElement() const; - virtual bool inq_IsSorted() const; - - // DATA - source_iterator itRun; - source_iterator itEnd; -}; - - - -//************************* SCI_Map **********************************// - -template <class KEY, class VALUE> -class SCI_Map : public StdConstIterator< typename std::map<KEY,VALUE>::value_type > -{ - public: - typedef std::map<KEY,VALUE> source; - typedef typename source::const_iterator source_iterator; - - SCI_Map( - const source & i_rSource ); - virtual ~SCI_Map(); - - private: - // Interface StdConstIterator<>: - virtual void do_Advance(); - virtual const typename std::map<KEY,VALUE>::value_type * - inq_CurElement() const; - virtual bool inq_IsSorted() const; - - // DATA - source_iterator itRun; - source_iterator itEnd; -}; - - -//************************* SCI_MultiMap **********************************// - -template <class KEY, class VALUE> -class SCI_MultiMap : public StdConstIterator< typename std::multimap<KEY,VALUE>::value_type > -{ - public: - typedef std::multimap<KEY,VALUE> source; - typedef typename source::const_iterator source_iterator; - - SCI_MultiMap( - const source & i_rSource ); - SCI_MultiMap( - source_iterator i_begin, - source_iterator i_end ); - virtual ~SCI_MultiMap(); - - private: - // Interface StdConstIterator<>: - virtual void do_Advance(); - virtual const typename std::multimap<KEY,VALUE>::value_type * - inq_CurElement() const; - virtual bool inq_IsSorted() const; - - // DATA - source_iterator itRun; - source_iterator itEnd; -}; - - - -//************************* SCI_Set **********************************// - - -template <class TYPES> -class SCI_Set : public StdConstIterator<typename TYPES::element_type> -{ - public: - typedef typename TYPES::element_type element; - typedef typename TYPES::sort_type sorter; - typedef std::set<element, sorter> source; - typedef typename source::const_iterator source_iterator; - - SCI_Set( - const source & i_rSource ); - virtual ~SCI_Set(); - - private: - // Interface StdConstIterator<>: - virtual void do_Advance(); - virtual const element * - inq_CurElement() const; - virtual bool inq_IsSorted() const; - - // DATA - source_iterator itRun; - source_iterator itEnd; -}; - -//************************* SCI_DataInMap **********************************// - -template <class KEY, class VALUE> -class SCI_DataInMap : public StdConstIterator<VALUE> -{ - public: - typedef std::map<KEY,VALUE> source; - typedef typename source::const_iterator source_iterator; - - SCI_DataInMap( - const source & i_rSource ); - virtual ~SCI_DataInMap(); - - private: - // Interface StdConstIterator<>: - virtual void do_Advance(); - virtual const VALUE * - inq_CurElement() const; - virtual bool inq_IsSorted() const; - - // DATA - source_iterator itRun; - source_iterator itEnd; -}; - - - - - -//********************************************************************// - - -// IMPLEMENTATION - -template <class ELEM> -SCI_Vector<ELEM>::SCI_Vector( const source & i_rSource ) - : itRun(i_rSource.begin()), - itEnd(i_rSource.end()) -{ -} - -template <class ELEM> -SCI_Vector<ELEM>::~SCI_Vector() -{ -} - - -template <class ELEM> -void -SCI_Vector<ELEM>::do_Advance() -{ - if (itRun != itEnd) - ++itRun; -} - -template <class ELEM> -const ELEM * -SCI_Vector<ELEM>::inq_CurElement() const -{ - if (itRun != itEnd) - return &(*itRun); - return 0; -} - -template <class ELEM> -bool -SCI_Vector<ELEM>::inq_IsSorted() const -{ - return false; -} - - - - -template <class KEY, class VALUE> -SCI_Map<KEY,VALUE>::SCI_Map( const source & i_rSource ) - : itRun(i_rSource.begin()), - itEnd(i_rSource.end()) -{ -} - -template <class KEY, class VALUE> -SCI_Map<KEY,VALUE>::~SCI_Map() -{ -} - -template <class KEY, class VALUE> -void -SCI_Map<KEY,VALUE>::do_Advance() -{ - if (itRun != itEnd) - ++itRun; -} - -template <class KEY, class VALUE> -const typename std::map<KEY,VALUE>::value_type * -SCI_Map<KEY,VALUE>::inq_CurElement() const -{ - if (itRun != itEnd) - return &(*itRun); - return 0; -} - - -template <class KEY, class VALUE> -bool -SCI_Map<KEY,VALUE>::inq_IsSorted() const -{ - return true; -} - - - - - - - -template <class KEY, class VALUE> -SCI_MultiMap<KEY,VALUE>::SCI_MultiMap( const source & i_rSource ) - : itRun(i_rSource.begin()), - itEnd(i_rSource.end()) -{ -} - -template <class KEY, class VALUE> -SCI_MultiMap<KEY,VALUE>::SCI_MultiMap( source_iterator i_begin, - source_iterator i_end ) - : itRun(i_begin), - itEnd(i_end) -{ -} - -template <class KEY, class VALUE> -SCI_MultiMap<KEY,VALUE>::~SCI_MultiMap() -{ -} - -template <class KEY, class VALUE> -void -SCI_MultiMap<KEY,VALUE>::do_Advance() -{ - if (itRun != itEnd) - ++itRun; -} - -template <class KEY, class VALUE> -const typename std::multimap<KEY,VALUE>::value_type * -SCI_MultiMap<KEY,VALUE>::inq_CurElement() const -{ - if (itRun != itEnd) - return &(*itRun); - return 0; -} - - -template <class KEY, class VALUE> -bool -SCI_MultiMap<KEY,VALUE>::inq_IsSorted() const -{ - return true; -} - - - - - - - - -template <class ELEM> -SCI_Set<ELEM>::SCI_Set( const source & i_rSource ) - : itRun(i_rSource.begin()), - itEnd(i_rSource.end()) -{ -} - -template <class ELEM> -SCI_Set<ELEM>::~SCI_Set() -{ -} - - -template <class ELEM> -void -SCI_Set<ELEM>::do_Advance() -{ - if (itRun != itEnd) - ++itRun; -} - -template <class ELEM> -const typename SCI_Set<ELEM>::element * -SCI_Set<ELEM>::inq_CurElement() const -{ - if (itRun != itEnd) - return &(*itRun); - return 0; -} - -template <class ELEM> -bool -SCI_Set<ELEM>::inq_IsSorted() const -{ - return true; -} - - - - - - - -template <class KEY, class VALUE> -SCI_DataInMap<KEY,VALUE>::SCI_DataInMap( const source & i_rSource ) - : itRun(i_rSource.begin()), - itEnd(i_rSource.end()) -{ -} - -template <class KEY, class VALUE> -SCI_DataInMap<KEY,VALUE>::~SCI_DataInMap() -{ -} - -template <class KEY, class VALUE> -void -SCI_DataInMap<KEY,VALUE>::do_Advance() -{ - if (itRun != itEnd) - ++itRun; -} - -template <class KEY, class VALUE> -const VALUE * -SCI_DataInMap<KEY,VALUE>::inq_CurElement() const -{ - if (itRun != itEnd) - return &(*itRun).second; - return 0; -} - - -template <class KEY, class VALUE> -bool -SCI_DataInMap<KEY,VALUE>::inq_IsSorted() const -{ - return true; -} - - - - - - - -} // namespace ary - - -#endif - -/* vim:set shiftwidth=4 softtabstop=4 expandtab: */ diff --git a/autodoc/source/ary/inc/store/s_base.hxx b/autodoc/source/ary/inc/store/s_base.hxx deleted file mode 100644 index 085db7616a34..000000000000 --- a/autodoc/source/ary/inc/store/s_base.hxx +++ /dev/null @@ -1,174 +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 ARY_STORE_S_BASE_HXX -#define ARY_STORE_S_BASE_HXX - -// USED SERVICES -#include <deque> -#include <cosv/tpl/tpltools.hxx> - - - - -namespace ary -{ -namespace stg -{ - - -/** The basic storage container of the repository. - - @collab Storage - Implements Storage. Not used elsewhere. - - @tpl ENTITY - The type of *it, where it is of type c_iter, has to be ENTITY * const. -*/ -template <class ENTITY> -class Base -{ - public: - // LIFECYCLE - typedef std::deque< ENTITY* > impl_type; - typedef typename impl_type::const_iterator c_iter; - - - /** @param i_nrOfReservedItems - The number of actual items to reserve, including the item - at index [0] that is always empty and unused. - */ - Base( - uintt i_nrOfReservedItems ); - ~Base(); - - // OPERATORS - ENTITY * operator[]( - uintt i_index ) const; - // OPERATIONS - uintt Add_Entity( /// @return the index of the new element. - DYN ENTITY & pass_newEntity ); - DYN ENTITY * Set_Entity( /// @return the previous value. - uintt i_index, - DYN ENTITY & pass_newEntity ); - // INQUIRY - uintt Size() const; /// Incl. reserved size. - uintt ReservedSize() const; /// Incl. zero for element at [0]. - - c_iter Begin() const; /// @return location of index 1, because 0 is always empty. - c_iter BeginUnreserved() const; - c_iter End() const; - - private: - // DATA - impl_type aData; - uintt nReservedSize; -}; - - - -// IMPLEMENTATION - -template <class ENTITY> -Base<ENTITY>::Base(uintt i_nrOfReservedItems) - : aData(i_nrOfReservedItems, 0), - nReservedSize(i_nrOfReservedItems) -{ -} - -template <class ENTITY> -Base<ENTITY>::~Base() -{ - csv::erase_container_of_heap_ptrs(aData); -} - - -template <class ENTITY> -ENTITY * -Base<ENTITY>::operator[](uintt i_index) const -{ - if (i_index < aData.size()) - return aData[i_index]; - return 0; -} - -template <class ENTITY> -uintt -Base<ENTITY>::Add_Entity(DYN ENTITY & pass_newEntity) -{ - aData.push_back(&pass_newEntity); - return aData.size() - 1; -} - -template <class ENTITY> -DYN ENTITY * -Base<ENTITY>::Set_Entity( uintt i_index, - DYN ENTITY & pass_newEntity ) -{ - csv_assert(i_index != 0 AND i_index < aData.size()); - - Dyn<ENTITY> - ret(aData[i_index]); - aData[i_index] = &pass_newEntity; - return ret.Release(); -} - -template <class ENTITY> -uintt -Base<ENTITY>::Size() const -{ - return aData.size(); -} - -template <class ENTITY> -uintt -Base<ENTITY>::ReservedSize() const -{ - return nReservedSize; -} - -template <class ENTITY> -typename Base<ENTITY>::c_iter -Base<ENTITY>::Begin() const -{ - return aData.begin() + 1; -} - -template <class ENTITY> -typename Base<ENTITY>::c_iter -Base<ENTITY>::BeginUnreserved() const -{ - return aData.begin() + nReservedSize; -} - -template <class ENTITY> -typename Base<ENTITY>::c_iter -Base<ENTITY>::End() const -{ - return aData.end(); -} - - - - -} // namespace stg -} // namespace ary -#endif - -/* vim:set shiftwidth=4 softtabstop=4 expandtab: */ diff --git a/autodoc/source/ary/inc/store/s_iterator.hxx b/autodoc/source/ary/inc/store/s_iterator.hxx deleted file mode 100644 index 1e5bd488449c..000000000000 --- a/autodoc/source/ary/inc/store/s_iterator.hxx +++ /dev/null @@ -1,231 +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 ARY_STORE_S_ITERATOR_HXX -#define ARY_STORE_S_ITERATOR_HXX - -// USED SERVICES -#include <ary/getncast.hxx> -#include "s_base.hxx" - - - - -namespace ary -{ -namespace stg -{ - - -template <class> class const_iterator; -template <class, class> class const_filter_iterator; - - -/** A non-const iterator that runs on a ->Storage<>. - - @collab Storage<> -*/ -template <class ENTITY> -class iterator : public std::iterator<std::forward_iterator_tag, ENTITY> -{ - public: - typedef iterator<ENTITY> self; - typedef typename Base<ENTITY>::impl_type impl_container; - typedef typename impl_container::const_iterator impl_type; - - // OPERATORS - iterator() - : itImpl() {} - explicit iterator( - impl_type i_impl) - : itImpl(i_impl) {} - ~iterator() {} - - bool operator==( - self i_other ) const - { return itImpl == i_other.itImpl; } - bool operator!=( - self i_other ) const - { return itImpl != i_other.itImpl; } - ENTITY & operator*() const { csv_assert(*itImpl != 0); - return *(*itImpl); } - self & operator++() { ++itImpl; return *this; } - self operator++(int) { return self(itImpl++); } - - private: - friend class const_iterator<ENTITY>; // For const_iterator(iterator); - impl_type ImplIterator() const { return itImpl; } - - // DATA - impl_type itImpl; -}; - - -/** A const iterator that runs on a ->Storage<>. - - @collab Storage<> -*/ -template <class ENTITY> -class const_iterator : - public std::iterator<std::forward_iterator_tag, const ENTITY> -{ - public: - typedef const_iterator<ENTITY> self; - typedef typename Base<ENTITY>::impl_type impl_container; - typedef typename impl_container::const_iterator impl_type; - - // OPERATORS - const_iterator() - : itImpl() {} - explicit const_iterator( - impl_type i_impl) - : itImpl(i_impl) {} - const_iterator( // implicit conversions allowed - ::ary::stg::iterator<ENTITY> i_it ) - : itImpl(i_it.ImplIterator()) {} - ~const_iterator() {} - - bool operator==( - self i_other ) const - { return itImpl == i_other.itImpl; } - bool operator!=( - self i_other ) const - { return itImpl != i_other.itImpl; } - const ENTITY & operator*() const { csv_assert(*itImpl != 0); - return *(*itImpl); } - self & operator++() { ++itImpl; return *this; } - self operator++(int) { return self(itImpl++); } - - private: - // DATA - impl_type itImpl; -}; - - - - - -/** A non const iterator that runs on a ->Storage<> and returns only - the elements of a specific type. - - @tpl ENTITY - The element type of the ->Storage<> - - @tpl FILTER - The actual type of the returned items. FILTER needs to be derived from - ENTITY. - - @collab Storage<> -*/ -template <class ENTITY, class FILTER> -class filter_iterator : - public std::iterator<std::forward_iterator_tag, FILTER> -{ - public: - typedef filter_iterator<ENTITY,FILTER> self; - typedef ::ary::stg::iterator<ENTITY> impl_type; - - // OPERATORS - filter_iterator() - : itCur() {} - explicit filter_iterator( - impl_type i_cur ) - : itCur(i_cur) {} - ~filter_iterator() {} - - bool operator==( - self i_other ) const - { return itCur == i_other.itCur; } - bool operator!=( - self i_other ) const - { return itCur != i_other.itCur; } - FILTER & operator*() const { csv_assert(IsValid()); - return static_cast< FILTER& >(*itCur); } - self & operator++() { ++itCur; - return *this; } - self operator++(int) { return self(itCur++); } - bool IsValid() const { return ary::is_type<FILTER>(*itCur); } - - private: - friend class const_filter_iterator<ENTITY,FILTER>; // For const_filter_iterator(filter_iterator); - impl_type ImplCur() const { return itCur; } - - // DATA - impl_type itCur; -}; - - -/** A const iterator that runs on a ->Storage<> and returns only - the elements of a specific type. - - @tpl ENTITY - The element type of the ->Storage<> - - @tpl FILTER - The actual type of the returned items. FILTER needs to be derived from - ENTITY. - - @collab Storage<> -*/ -template <class ENTITY, class FILTER> -class const_filter_iterator : - public std::iterator<std::forward_iterator_tag, const FILTER> -{ - public: - typedef const_filter_iterator<ENTITY,FILTER> self; - typedef ::ary::stg::const_iterator<ENTITY> impl_type; - - // OPERATORS - const_filter_iterator() - : itCur() {} - explicit const_filter_iterator( - impl_type i_cur ) - : itCur(i_cur) {} - explicit const_filter_iterator( // implicit conversions allowed - filter_iterator<ENTITY,FILTER> - i_it ) - : itCur(i_it.ImplCur()) {} - ~const_filter_iterator() - {} - bool operator==( - self i_other ) const - { return itCur == i_other.itCur; } - bool operator!=( - self i_other ) const - { return itCur != i_other.itCur; } - const FILTER & operator*() const { csv_assert(IsValid()); - return static_cast< const FILTER& >(*itCur); } - self & operator++() { ++itCur; - return *this; } - self operator++(int) { return self(itCur++); } - bool IsValid() const { return ary::is_type<FILTER>(*itCur); } - - private: - // DATA - impl_type itCur; -}; - - - - -} // namespace stg -} // namespace ary -#endif - -/* vim:set shiftwidth=4 softtabstop=4 expandtab: */ diff --git a/autodoc/source/ary/inc/store/s_storage.hxx b/autodoc/source/ary/inc/store/s_storage.hxx deleted file mode 100644 index 4bb393b48f93..000000000000 --- a/autodoc/source/ary/inc/store/s_storage.hxx +++ /dev/null @@ -1,288 +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 ARY_STORE_S_STORAGE_HXX -#define ARY_STORE_S_STORAGE_HXX - -// USED SERVICES -#include <ary/types.hxx> -#include "s_iterator.hxx" - - - - -namespace ary -{ -namespace stg -{ - - -/** The storage unit of one class of commomly stored repository - entities. -*/ -template <class ENTITY> -class Storage -{ - public: - typedef Base<ENTITY> container_type; - typedef ary::TypedId<ENTITY> key_type; - typedef stg::const_iterator<ENTITY> c_iter; - typedef stg::iterator<ENTITY> iter; - - // LIFECYCLE - virtual ~Storage() {} - - // OPERATORS - const ENTITY & operator[]( - key_type i_id ) const; - ENTITY & operator[]( - key_type i_id ); - const ENTITY & operator[]( - Rid i_index ) const; - ENTITY & operator[]( - Rid i_index ); - // OPERATIONS - /// Sets the id of the new entity. - key_type Store_Entity( - DYN ENTITY & pass_newEntity ); - /// Sets the id of the new entity. - void Set_Reserved( - uintt i_index, - DYN ENTITY & pass_newEntity ); - /// Sets the id of the new entity. - void Replace_Entity( - key_type i_index, - DYN ENTITY & pass_newEntity ); - // INQUIRY - bool Exists( - key_type i_id ) const; - bool Exists( - Rid i_index ) const; - - c_iter Begin() const; - c_iter BeginUnreserved() const; - c_iter End() const; - - // ACCESS - iter Begin(); - iter BeginUnreserved(); - iter End(); - - protected: - Storage( - uintt i_nrOfReservedItems ); - private: - // DATA - container_type aData; -}; - - - - - - -// IMPLEMENTATION - -// Used later, so implemented first. -template <class ENTITY> -inline bool -Storage<ENTITY>::Exists(Rid i_index) const -{ - return 0 < i_index AND i_index < aData.Size(); -} - -template <class ENTITY> -inline bool -Storage<ENTITY>::Exists(key_type i_id) const -{ - return Exists(i_id.Value()); -} - -template <class ENTITY> -inline const ENTITY & -Storage<ENTITY>::operator[](Rid i_index) const -{ - csv_assert(Exists(i_index)); - return * aData[i_index]; -} - -template <class ENTITY> -inline ENTITY & -Storage<ENTITY>::operator[](Rid i_index) -{ - csv_assert(Exists(i_index)); - return * aData[i_index]; -} - -template <class ENTITY> -inline const ENTITY & -Storage<ENTITY>::operator[](key_type i_id) const -{ - return operator[](i_id.Value()); -} - -template <class ENTITY> -inline ENTITY & -Storage<ENTITY>::operator[](key_type i_id) -{ - return operator[](i_id.Value()); -} - -template <class ENTITY> -typename Storage<ENTITY>::key_type -Storage<ENTITY>::Store_Entity(DYN ENTITY & pass_newEntity) -{ - csv_assert( aData.Size() >= aData.ReservedSize() ); - Rid - ret( aData.Add_Entity(pass_newEntity) ); - pass_newEntity.Set_Id(ret); - return key_type(ret); -} - -template <class ENTITY> -void -Storage<ENTITY>::Set_Reserved(uintt i_index, - DYN ENTITY & pass_newEntity) -{ - // 0 must not be used. - csv_assert( i_index != 0 ); - // Make sure, i_index actually is the id of a reserved item. - csv_assert( i_index < aData.ReservedSize() ); - - // If there was a previous entity, it will be deleted by - // the destructor of pOldEntity. - Dyn<ENTITY> - pOldEntity(aData.Set_Entity(i_index, pass_newEntity)); - pass_newEntity.Set_Id(i_index); -} - -template <class ENTITY> -void -Storage<ENTITY>::Replace_Entity( key_type i_index, - DYN ENTITY & pass_newEntity ) -{ - uintt - nIndex = i_index.Value(); - // Make sure, i_index actually is the id of an existing, - // non reserved entity. - csv_assert( csv::in_range(aData.ReservedSize(), nIndex, aData.Size()) ); - - // If there was a previous entity, it will be deleted by - // the destructor of pOldEntity. - Dyn<ENTITY> - pOldEntity(aData.Set_Entity(nIndex, pass_newEntity)); - pass_newEntity.Set_Id(nIndex); -} - -template <class ENTITY> -inline -typename Storage<ENTITY>::c_iter -Storage<ENTITY>::Begin() const -{ - return c_iter(aData.Begin()); -} - -template <class ENTITY> -inline -typename Storage<ENTITY>::c_iter -Storage<ENTITY>::BeginUnreserved() const -{ - return c_iter(aData.BeginUnreserved()); -} - -template <class ENTITY> -inline -typename Storage<ENTITY>::c_iter -Storage<ENTITY>::End() const -{ - return c_iter(aData.End()); -} - -template <class ENTITY> -inline -typename Storage<ENTITY>::iter -Storage<ENTITY>::Begin() -{ - return iter(aData.Begin()); -} - -template <class ENTITY> -inline -typename Storage<ENTITY>::iter -Storage<ENTITY>::BeginUnreserved() -{ - return iter(aData.BeginUnreserved()); -} - -template <class ENTITY> -inline -typename Storage<ENTITY>::iter -Storage<ENTITY>::End() -{ - return iter(aData.End()); -} - -template <class ENTITY> -inline -Storage<ENTITY>::Storage(uintt i_nrOfReservedItems) - : aData(i_nrOfReservedItems) -{ - // Make sure Rid and uintt are the same type, because - // the interface of this uses Rid, but the interface of - // container_type uses uintt. - csv_assert( sizeof(uintt) == sizeof(Rid) ); -} - - - - -// HELPER FUNCTIONS - -/** @return 0, if data are not there. -*/ -template <class ENTITY> -inline const ENTITY * -Search( const Storage<ENTITY> & i_storage, - Rid i_id ) -{ - if (NOT i_storage.Exists(i_id)) - return 0; - return &i_storage[i_id]; -} - -/** @return 0, if data are not there. -*/ -template <class ENTITY> -inline ENTITY * -SearchAccess( const Storage<ENTITY> & i_storage, - Rid i_id ) -{ - if (NOT i_storage.Exists(i_id)) - return 0; - return &i_storage[i_id]; -} - - - - -} // namespace stg -} // namespace ary -#endif - -/* vim:set shiftwidth=4 softtabstop=4 expandtab: */ diff --git a/autodoc/source/ary/info/all_dts.cxx b/autodoc/source/ary/info/all_dts.cxx deleted file mode 100644 index 3a1f2daa3c90..000000000000 --- a/autodoc/source/ary/info/all_dts.cxx +++ /dev/null @@ -1,98 +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 . - */ - -#include <precomp.h> -#include <ary/info/all_dts.hxx> - - -// NOT FULLY DEFINED SERVICES -#include <ary/info/infodisp.hxx> - - -namespace ary -{ -namespace info -{ - - -void -DT_Text::do_StoreAt( DocuDisplay & o_rDisplay ) const -{ - o_rDisplay.Display_DT_Text(*this); -} - -bool -DT_Text::inq_IsWhite() const -{ - return false; -} - -void -DT_MaybeLink::do_StoreAt( DocuDisplay & o_rDisplay ) const -{ - o_rDisplay.Display_DT_MaybeLink(*this); -} - -bool -DT_MaybeLink::inq_IsWhite() const -{ - return false; -} - -void -DT_Whitespace::do_StoreAt( DocuDisplay & o_rDisplay ) const -{ - o_rDisplay.Display_DT_Whitespace(*this); -} - -bool -DT_Whitespace::inq_IsWhite() const -{ - return true; -} - -void -DT_Eol::do_StoreAt( DocuDisplay & o_rDisplay ) const -{ - o_rDisplay.Display_DT_Eol(*this); -} - -bool -DT_Eol::inq_IsWhite() const -{ - return true; -} - -void -DT_Xml::do_StoreAt( DocuDisplay & o_rDisplay ) const -{ - o_rDisplay.Display_DT_Xml(*this); -} - -bool -DT_Xml::inq_IsWhite() const -{ - return false; -} - - -} // namespace info -} // namespace ary - -/* vim:set shiftwidth=4 softtabstop=4 expandtab: */ diff --git a/autodoc/source/ary/info/all_tags.cxx b/autodoc/source/ary/info/all_tags.cxx deleted file mode 100644 index 8009cb4f1513..000000000000 --- a/autodoc/source/ary/info/all_tags.cxx +++ /dev/null @@ -1,353 +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 . - */ - -#include <precomp.h> -#include <ary/info/all_tags.hxx> - - -// NOT FULLY DEFINED SERVICES -#include <limits> -#include <ary/info/infodisp.hxx> -#include <adc_cl.hxx> - - -namespace ary -{ -namespace info -{ - - - -//***************************** StdTag ***********************// - - -StdTag::StdTag( E_AtTagId i_eId ) - : eId(i_eId), - // aText, - pNext(0) -{ -} - -bool -StdTag::Add_SpecialMeaningToken( const char * , - intt ) -{ - // Does nothing - - // KORR_FUTURE - // Should be a logical exception: - // csv_assert(false); - return false; -} - -UINT8 -StdTag::NrOfSpecialMeaningTokens() const -{ - return 0; -} - -AtTag * -StdTag::GetFollower() -{ - if (pNext != 0) - return pNext->GetFollower(); - pNext = new StdTag(eId); - return pNext; -} - -void -StdTag::do_StoreAt( DocuDisplay & o_rDisplay ) const -{ - o_rDisplay.Display_StdTag( *this ); -} - -DocuText * -StdTag::Text() -{ - return &aText; -} - - - -//***************************** BaseTag ***********************// - -BaseTag::BaseTag() - : // sBase - // aText - pNext(0) -{ -} - -bool -BaseTag::Add_SpecialMeaningToken( const char * i_sText, - intt i_nNr ) -{ - if ( i_nNr == 1 ) - { - sBase.AssignText(i_sText,"::"); - return true; - } - return false; -} - -const char * -BaseTag::Title() const -{ - return "Base Classes"; -} - -UINT8 -BaseTag::NrOfSpecialMeaningTokens() const -{ - return 1; -} - -AtTag * -BaseTag::GetFollower() -{ - if (pNext != 0) - return pNext->GetFollower(); - pNext = new BaseTag; - return pNext; -} - -DocuText * -BaseTag::Text() -{ - return &aText; -} - - - -//***************************** ExceptionTag ***********************// - -ExceptionTag::ExceptionTag() - : // sException, - // aText - pNext(0) -{ -} - -bool -ExceptionTag::Add_SpecialMeaningToken( const char * i_sText, - intt i_nNr ) -{ - if ( i_nNr == 1 ) - { - sException.AssignText(i_sText,"::"); - return true; - } - return false; -} - -const char * -ExceptionTag::Title() const -{ - return "Thrown Exceptions"; -} - -UINT8 -ExceptionTag::NrOfSpecialMeaningTokens() const -{ - return 1; -} - -AtTag * -ExceptionTag::GetFollower() -{ - if (pNext != 0) - return pNext->GetFollower(); - pNext = new ExceptionTag; - return pNext; -} - -DocuText * -ExceptionTag::Text() -{ - return &aText; -} - - -//***************************** ImplementsTag ***********************// - -ImplementsTag::ImplementsTag() - : // sBase - // aText - pNext(0) -{ -} - -bool -ImplementsTag::Add_SpecialMeaningToken( const char * i_sText, - intt i_nNr ) -{ - if ( i_nNr == 1 ) - { - sName.AssignText(i_sText,"::"); - } - else - { - GetFollower()->Add_SpecialMeaningToken(i_sText,1); - } - return true; -} - -const char * -ImplementsTag::Title() const -{ - return "Implements"; -} - -UINT8 -ImplementsTag::NrOfSpecialMeaningTokens() const -{ - return std::numeric_limits<UINT8>::max(); -} - -AtTag * -ImplementsTag::GetFollower() -{ - if (pNext != 0) - return pNext->GetFollower(); - pNext = new ImplementsTag; - return pNext; -} - -DocuText * -ImplementsTag::Text() -{ - return 0; -} - -//***************************** ParameterTag ***********************// - - -ParameterTag::ParameterTag() - : // sName - // aText - pNext(0) -{ -} - -bool -ParameterTag::Add_SpecialMeaningToken( const char * i_sText, - intt i_nNr ) -{ - if ( i_nNr == 1 ) - { - sName = i_sText; - return true; - } - else if (i_nNr == 2) - { - uintt nLen = strlen(i_sText); - if (*i_sText == '[' AND i_sText[nLen-1] == ']') - { - sValidRange = String(i_sText+1, nLen-2); - return true; - } - } - return false; -} - -UINT8 -ParameterTag::NrOfSpecialMeaningTokens() const -{ - return 2; -} - -AtTag * -ParameterTag::GetFollower() -{ - if (pNext != 0) - return pNext->GetFollower(); - return pNext = new ParameterTag; -} - -DocuText * -ParameterTag::Text() -{ - return &aText; -} - -void -ParameterTag::do_StoreAt( DocuDisplay & o_rDisplay ) const -{ - o_rDisplay.Display_ParameterTag( *this ); -} - -//***************************** TemplateTag ***********************// - - -TemplateTag::TemplateTag() - : // sName - // aText - pNext(0) -{ -} - -bool -TemplateTag::Add_SpecialMeaningToken( const char * i_sText, - intt i_nNr ) -{ - if ( i_nNr == 1 ) - { - sName = i_sText; - return true; - } - return false; -} - -const char * -TemplateTag::Title() const -{ - return "Template Parameters"; -} - -UINT8 -TemplateTag::NrOfSpecialMeaningTokens() const -{ - return 1; -} - -AtTag * -TemplateTag::GetFollower() -{ - if (pNext != 0) - return pNext->GetFollower(); - return pNext = new TemplateTag; -} - -void -TemplateTag::do_StoreAt( DocuDisplay & o_rDisplay ) const -{ - o_rDisplay.Display_TemplateTag( *this ); -} - - -DocuText * -TemplateTag::Text() -{ - return &aText; -} - -} // namespace info -} // namespace ary - -/* vim:set shiftwidth=4 softtabstop=4 expandtab: */ diff --git a/autodoc/source/ary/info/ci_attag.cxx b/autodoc/source/ary/info/ci_attag.cxx deleted file mode 100644 index 7bf36c441aa4..000000000000 --- a/autodoc/source/ary/info/ci_attag.cxx +++ /dev/null @@ -1,78 +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 . - */ - -#include <precomp.h> -#include <ary/info/ci_attag.hxx> - - -// NOT FULLY DEFINED SERVICES -#include <ary/info/all_dts.hxx> -#include <ary/info/ci_text.hxx> - - -namespace ary -{ -namespace info -{ - -void -AtTag::Add_Token( const char * i_sText ) -{ - DocuText * pText = Text(); - if (pText != 0) - pText->Add_Token( *new DT_Text(i_sText) ); -} - -void -AtTag::Add_PotentialLink( const char * i_sText, - bool i_bIsGlobal, - bool i_bIsFunction ) -{ - DocuText * pText = Text(); - if (pText != 0) - pText->Add_Token( *new DT_MaybeLink(i_sText, i_bIsGlobal, i_bIsFunction) ); -} - -void -AtTag::Add_Whitespace( UINT8 i_nLength ) -{ - DocuText * pText = Text(); - if (pText != 0) - pText->Add_Token( *new DT_Whitespace(i_nLength) ); -} - -void -AtTag::Add_Eol() -{ - DocuText * pText = Text(); - if (pText != 0) - pText->Add_Token( *new DT_Eol ); -} - -void -AtTag::do_StoreAt( DocuDisplay & ) const -{ - // Dummy -} - -} // namespace info -} // namespace ary - - -/* vim:set shiftwidth=4 softtabstop=4 expandtab: */ diff --git a/autodoc/source/ary/info/ci_text.cxx b/autodoc/source/ary/info/ci_text.cxx deleted file mode 100644 index 0edf58627bda..000000000000 --- a/autodoc/source/ary/info/ci_text.cxx +++ /dev/null @@ -1,52 +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 . - */ - -#include <precomp.h> -#include <ary/info/ci_text.hxx> - - -// NOT FULLY DEFINED SERVICES -#include <ary/info/all_dts.hxx> - - -namespace ary -{ -namespace info -{ - -DocuText::DocuText() - : bUsesHtml(false) -{ -} - -DocuText::~DocuText() -{ - for ( TokenList::iterator iter = aTokens.begin(); - iter != aTokens.end(); - ++iter ) - { - delete (*iter); - } -} - -} // namespace info -} // namespace ary - - -/* vim:set shiftwidth=4 softtabstop=4 expandtab: */ diff --git a/autodoc/source/ary/kernel/namesort.cxx b/autodoc/source/ary/kernel/namesort.cxx deleted file mode 100644 index f6e8eb11fec3..000000000000 --- a/autodoc/source/ary/kernel/namesort.cxx +++ /dev/null @@ -1,94 +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 . - */ - -#include <precomp.h> -#include <ary/namesort.hxx> - - -// NOT FULLY DEFINED SERVICES - - - -namespace -{ - - -int C_cAutodocNameOrdering1[256] = - { 0,255,255,255, 255,255,255,255, 255,255,255,255, 255,255,255,255, // 0 .. - 255,255,255,255, 255,255,255,255, 255,255,255,255, 255,255,255,255, - 255,255,255,255, 255,255,255,255, 255,255,255,255, 255,255,255,255, // 32 .. - 70, 71, 72, 73, 74, 75, 76, 77, 78, 79,255,255, 255,255,255,255, - - 255, 11, 13, 15, 17, 19, 21, 23, 25, 27, 29, 31, 33, 35, 37, 39, // 64 .. - 41, 43, 45, 47, 49, 51, 53, 55, 57, 59, 61,255, 255,255,255, 63, - 255, 11, 13, 15, 17, 19, 21, 23, 25, 27, 29, 31, 33, 35, 37, 39, // 96 .. - 41, 43, 45, 47, 49, 51, 53, 55, 57, 59, 61,255, 255,255,255,255, - - 255,255,255,255, 255,255,255,255, 255,255,255,255, 255,255,255,255, //128 .. - 255,255,255,255, 255,255,255,255, 255,255,255,255, 255,255,255,255, - 255,255,255,255, 255,255,255,255, 255,255,255,255, 255,255,255,255, //160 .. - 255,255,255,255, 255,255,255,255, 255,255,255,255, 255,255,255,255, - - 255,255,255,255, 255,255,255,255, 255,255,255,255, 255,255,255,255, - 255,255,255,255, 255,255,255,255, 255,255,255,255, 255,255,255,255, - 255,255,255,255, 255,255,255,255, 255,255,255,255, 255,255,255,255, - 255,255,255,255, 255,255,255,255, 255,255,255,255, 255,255,255,255 - }; - -int C_cAutodocNameOrdering2[256] = - { 0,255,255,255, 255,255,255,255, 255,255,255,255, 255,255,255,255, // 0 .. - 255,255,255,255, 255,255,255,255, 255,255,255,255, 255,255,255,255, - 255,255,255,255, 255,255,255,255, 255,255,255,255, 255,255,255,255, // 32 .. - 70, 71, 72, 73, 74, 75, 76, 77, 78, 79,255,255, 255,255,255,255, - - 255, 11, 13, 15, 17, 19, 21, 23, 25, 27, 29, 31, 33, 35, 37, 39, // 64 .. - 41, 43, 45, 47, 49, 51, 53, 55, 57, 59, 61,255, 255,255,255, 63, - 255, 12, 14, 16, 18, 20, 22, 24, 26, 28, 30, 32, 34, 36, 38, 40, // 96 .. - 42, 44, 46, 48, 50, 52, 54, 56, 58, 60, 62,255, 255,255,255,255, - - 255,255,255,255, 255,255,255,255, 255,255,255,255, 255,255,255,255, //128 .. - 255,255,255,255, 255,255,255,255, 255,255,255,255, 255,255,255,255, - 255,255,255,255, 255,255,255,255, 255,255,255,255, 255,255,255,255, //160 .. - 255,255,255,255, 255,255,255,255, 255,255,255,255, 255,255,255,255, - - 255,255,255,255, 255,255,255,255, 255,255,255,255, 255,255,255,255, - 255,255,255,255, 255,255,255,255, 255,255,255,255, 255,255,255,255, - 255,255,255,255, 255,255,255,255, 255,255,255,255, 255,255,255,255, - 255,255,255,255, 255,255,255,255, 255,255,255,255, 255,255,255,255 - }; - - -} // namespace anonymous - - -namespace ary -{ - - -const csv::CharOrder_Table -LesserName::aOrdering1_(C_cAutodocNameOrdering1); - -const csv::CharOrder_Table -LesserName::aOrdering2_(C_cAutodocNameOrdering2); - - - -} // namespace ary - -/* vim:set shiftwidth=4 softtabstop=4 expandtab: */ diff --git a/autodoc/source/ary/kernel/qualiname.cxx b/autodoc/source/ary/kernel/qualiname.cxx deleted file mode 100644 index dd2ed5a9011c..000000000000 --- a/autodoc/source/ary/kernel/qualiname.cxx +++ /dev/null @@ -1,99 +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 . - */ - -#include <precomp.h> -#include <ary/qualiname.hxx> - - -// NOT FULLY DECLARED SERVICES - - -namespace ary -{ - - -QualifiedName::QualifiedName( uintt i_nSize ) - : aNamespace(), - sLocalName(), - bIsAbsolute(false), - bIsFunction() -{ - if (i_nSize > 0) - aNamespace.reserve(i_nSize); -} - -QualifiedName::QualifiedName( const char * i_sText, - const char * i_sSeparator ) - : aNamespace(), - sLocalName(), - bIsAbsolute(false), - bIsFunction() -{ - AssignText(i_sText,i_sSeparator); -} - -QualifiedName::~QualifiedName() -{ -} - -void -QualifiedName::AssignText( const char * i_sText, - const char * i_sSeparator ) -{ - csv_assert(NOT csv::no_str(i_sText) AND NOT csv::no_str(i_sSeparator)); - bIsAbsolute = false; - bIsFunction = false; - csv::erase_container( aNamespace ); - - uintt nSepLen = strlen(i_sSeparator); - const char * sNext = i_sText; - - const char * ps = strstr( i_sText, i_sSeparator ); - if (ps == i_sText) - { - bIsAbsolute = true; - sNext = ps + nSepLen; - } - - for ( ps = strstr(sNext, i_sSeparator); - ps != 0; - ps = strstr(sNext, i_sSeparator) ) - { - String sPart(sNext, ps - sNext); - aNamespace.push_back(sPart); - sNext = ps + nSepLen; - } - - uintt sNameLen = strlen(sNext); - if ( sNameLen > 2 ) - { - ps = sNext + sNameLen - 2; - if (*ps == '(' AND *(ps+1) == ')') - { - sNameLen -= 2; - bIsFunction = true; - } - } - sLocalName = String(sNext,sNameLen); -} - - -} // namespace ary - -/* vim:set shiftwidth=4 softtabstop=4 expandtab: */ diff --git a/autodoc/source/ary/kernel/reposy.cxx b/autodoc/source/ary/kernel/reposy.cxx deleted file mode 100644 index 5436f844883e..000000000000 --- a/autodoc/source/ary/kernel/reposy.cxx +++ /dev/null @@ -1,144 +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 . - */ - -#include <precomp.h> -#include <reposy.hxx> - - -// NOT FULLY DECLARED SERVICES -#include <idl_internalgate.hxx> - - -namespace ary -{ - - -//***************** Repository ************// - -DYN Repository & -Repository::Create_() -{ - return *new RepositoryCenter; -} - - - - -RepositoryCenter::RepositoryCenter() - : sDisplayedName(), - aLocation(), - pIdlPartition(0) -{ - pIdlPartition = & idl::InternalGate::Create_Partition_(); -} - -RepositoryCenter::~RepositoryCenter() -{ -} - -const ::ary::idl::Gate & -RepositoryCenter::Gate_Idl() const -{ - csv_assert(pIdlPartition); - return *pIdlPartition; -} - -const String & -RepositoryCenter::Title() const -{ - return sDisplayedName; -} - -::ary::idl::Gate & -RepositoryCenter::Gate_Idl() -{ - csv_assert(pIdlPartition); - return *pIdlPartition; -} - -void -RepositoryCenter::Set_Title(const String & i_sName) -{ - sDisplayedName = i_sName; -} - - - - -//********************* Repository Type Info Data ****************// - -// !!! IMPORTANT - NEVER DELETE OR CHANGE - ADDING ALLOWED - - - -/* ClassType-Ids - ------------- - - idl 2000 - information 5000 - logic location 6000 - phys location 7000 - sec. prod. 8000 - - - idl - --- - - Module 2000 - Interface 2001 - Function 2002 - Service 2003 - Property 2004 - Enum 2005 - EnumValue 2006 - Typedef 2007 - Struct 2008 - StructElement 2009 - Exception 2010 - ConstantGroup 2011 - Constant 2012 - Singleton 2013 - Attribute 2014 - SglIfcService 2015 - SglIfcSingleton 2016 - - BuiltInType 2200 - CeType 2201 - Sequence 2202 - ExplicitType 2203 - ExplicitNameRoom 2204 - TemplateParamType 2205 - - physical location - ----------------- - Root 7000 - Directory 7030 - File 7100 - - - info - ---- - CodeInformation - (IDL) 11002 -*/ - - -} // namespace ary - -/* vim:set shiftwidth=4 softtabstop=4 expandtab: */ |